diff --git a/src/Generator/Generators/CSharp/CSharpMarshal.cs b/src/Generator/Generators/CSharp/CSharpMarshal.cs index 0366c35d..db560b61 100644 --- a/src/Generator/Generators/CSharp/CSharpMarshal.cs +++ b/src/Generator/Generators/CSharp/CSharpMarshal.cs @@ -495,7 +495,7 @@ namespace CppSharp.Generators.CSharp Context.Return.Write("&_{0}", param.Name); } else - Context.Return.Write(Helpers.SafeIdentifier(Context.Parameter.Name)); + Context.Return.Write(Context.Parameter.Name); return true; } diff --git a/tests/Basic/Basic.cpp b/tests/Basic/Basic.cpp index 9d8c6d11..66e15404 100644 --- a/tests/Basic/Basic.cpp +++ b/tests/Basic/Basic.cpp @@ -36,6 +36,10 @@ char Foo2::testCharMarshalling(char c) return c; } +void Foo2::testKeywordParam(void* where) +{ +} + Bar::Bar() { } diff --git a/tests/Basic/Basic.h b/tests/Basic/Basic.h index cd3e992b..92272ce2 100644 --- a/tests/Basic/Basic.h +++ b/tests/Basic/Basic.h @@ -51,6 +51,7 @@ public: Foo2 operator<<(signed long l); Bar valueTypeField; char testCharMarshalling(char c); + void testKeywordParam(void* where); }; DLL_API Bar::Item operator |(Bar::Item left, Bar::Item right);