From b4e66d578a10c433efe7a5eff6d4b57f3585613b Mon Sep 17 00:00:00 2001 From: triton Date: Sun, 26 May 2013 18:22:25 +0100 Subject: [PATCH] Formatting fixes. --- src/Generator/Generators/CSharp/CSharpTextTemplate.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs index afb32c6b..8a29bd23 100644 --- a/src/Generator/Generators/CSharp/CSharpTextTemplate.cs +++ b/src/Generator/Generators/CSharp/CSharpTextTemplate.cs @@ -26,7 +26,7 @@ namespace CppSharp.Generators.CSharp public static string GeneratedIdentifier(string id) { - return "__" + id; + return "_" + id; } public static string SafeIdentifier(string id) @@ -576,6 +576,8 @@ namespace CppSharp.Generators.CSharp } } + #endregion + private void GenerateFieldProperty(Field field) { var @class = field.Class; @@ -944,7 +946,6 @@ namespace CppSharp.Generators.CSharp // Output a default constructor that takes the native pointer. GenerateNativeConstructor(@class); - NeedNewLine(); foreach (var ctor in @class.Constructors) { @@ -1030,7 +1031,6 @@ namespace CppSharp.Generators.CSharp { WriteLine("var {0} = (Internal*){1}.ToPointer();", Helpers.GeneratedIdentifier("ptr"), "native"); - GenerateStructMarshalingFields(@class); } @@ -1062,7 +1062,7 @@ namespace CppSharp.Generators.CSharp if (hasBase && !@class.IsValueType) { PushIndent(); - Write(": this(", QualifiedIdentifier(@class.Bases[0].Class)); + Write(": this("); if (method != null) Write("IntPtr.Zero");