From 3c31179db1e8a4a2f008612fb005124b946cc793 Mon Sep 17 00:00:00 2001 From: Joao Matos Date: Fri, 21 Jul 2023 01:47:16 +0100 Subject: [PATCH] Use TypePrinter.IntPtrType in CSharpSources.cs code from previous commit. --- src/Generator/Generators/CSharp/CSharpSources.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Generator/Generators/CSharp/CSharpSources.cs b/src/Generator/Generators/CSharp/CSharpSources.cs index 68a25dab..30145f00 100644 --- a/src/Generator/Generators/CSharp/CSharpSources.cs +++ b/src/Generator/Generators/CSharp/CSharpSources.cs @@ -1293,7 +1293,7 @@ internal static bool {Helpers.TryGetNativeToManagedMappingIdentifier}(IntPtr nat ptr = $"*{ptr}"; pointerType = pointerType.Pointee.Desugar() as PointerType; } - ptr = $"(IntPtr*)({ptr})"; + ptr = $"({TypePrinter.IntPtrType}*)({ptr})"; } var arrayType = var.Type.Desugar() as ArrayType;