diff --git a/unity/Assets/core/upm/Editor/Src/Generator/IL2Cpp/InstructionsFilter.cs b/unity/Assets/core/upm/Editor/Src/Generator/IL2Cpp/InstructionsFilter.cs index 092b6e17b1..31865dc900 100644 --- a/unity/Assets/core/upm/Editor/Src/Generator/IL2Cpp/InstructionsFilter.cs +++ b/unity/Assets/core/upm/Editor/Src/Generator/IL2Cpp/InstructionsFilter.cs @@ -95,10 +95,14 @@ static BindingMode FilterBigStructAndPointerOfPointer(MemberInfo memberInfo) { return BindingMode.DontBinding; } - if (ptype.IsByRef || ptype.IsPointer || ptype == typeof(System.IntPtr) || ptype == typeof(System.UIntPtr)) + if (ptype.IsByRef || ptype.IsPointer) { return BindingMode.DontBinding; } + if (ptype == typeof(System.IntPtr) || ptype == typeof(System.UIntPtr)) + { + return BindingMode.SlowBinding; + } } }