소스 검색

Merge pull request #88268 from zaevi/dotnet/fix_64bit_promotion

C#: Fix missing CowData 64-bit promotion for `PackedInt32Array`.
Rémi Verschelde 1 년 전
부모
커밋
fb688b38d1
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      modules/mono/glue/GodotSharp/GodotSharp/Core/NativeInterop/InteropStructs.cs

+ 1 - 1
modules/mono/glue/GodotSharp/GodotSharp/Core/NativeInterop/InteropStructs.cs

@@ -962,7 +962,7 @@ namespace Godot.NativeInterop
         public readonly unsafe int Size
         {
             [MethodImpl(MethodImplOptions.AggressiveInlining)]
-            get => _ptr != null ? *(_ptr - 1) : 0;
+            get => _ptr != null ? (int)(*((ulong*)_ptr - 1)) : 0;
         }
     }