diff --git a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs index 6425fe5b..b66eb519 100644 --- a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs +++ b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs @@ -1903,7 +1903,7 @@ namespace CppSharp.Generators.CSharp if (!@class.IsAbstract) { PushBlock(CSharpBlockKind.Method); - WriteLine("public static {0} {1}(global::System.IntPtr native)", safeIdentifier, Helpers.CreateInstanceIdentifier); + WriteLine("public static new {0} {1}(global::System.IntPtr native)", safeIdentifier, Helpers.CreateInstanceIdentifier); WriteStartBraceIndent(); WriteLine("return new {0}(({1}.Internal*) native);", safeIdentifier, className); WriteCloseBraceIndent();