From 408e17789e8fd48f367a3012d6eb1bd6233d4538 Mon Sep 17 00:00:00 2001 From: Jerome Laban Date: Thu, 26 Jan 2023 12:03:48 -0500 Subject: [PATCH] fix(android): Workaround IntPtr.Size intrinsics on 32/64 bits differences --- src/Uno.UI/UI/Xaml/SpecializedResourceDictionary.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/Uno.UI/UI/Xaml/SpecializedResourceDictionary.cs b/src/Uno.UI/UI/Xaml/SpecializedResourceDictionary.cs index 7acf98e22b09..2becd2b2878a 100644 --- a/src/Uno.UI/UI/Xaml/SpecializedResourceDictionary.cs +++ b/src/Uno.UI/UI/Xaml/SpecializedResourceDictionary.cs @@ -14,6 +14,7 @@ using System.Diagnostics; using System.Diagnostics.CodeAnalysis; using System.Runtime.CompilerServices; +using System.Runtime.InteropServices; using System.Runtime.Serialization; using Uno.Foundation; @@ -117,7 +118,7 @@ public static implicit operator ResourceKey(Type key) private Entry[] _entries; #if TARGET_64BIT private ulong _fastModMultiplier; - private static bool Is64Bits = IntPtr.Size >= 8 + private static bool Is64Bits = Marshal.SizeOf(typeof(IntPtr)) >= 8 #if __WASM__ || WebAssemblyRuntime.IsWebAssembly; #else