diff --git a/src/Generator/Passes/RenamePass.cs b/src/Generator/Passes/RenamePass.cs index 8549977c..6e1004b5 100644 --- a/src/Generator/Passes/RenamePass.cs +++ b/src/Generator/Passes/RenamePass.cs @@ -131,6 +131,9 @@ namespace CppSharp.Passes let pointerType = typedefDecl.Type.Desugar() as PointerType where pointerType != null && pointerType.Pointee is FunctionType select typedefDecl); + var specialization = decl as ClassTemplateSpecialization; + if (specialization != null) + declarations.RemoveAll(d => specialization.TemplatedDecl.TemplatedDecl == d); var result = declarations.Any(d => d != decl && d.Name == newName); if (result) diff --git a/tests/CSharp/CSharp.h b/tests/CSharp/CSharp.h index 01b464de..a49c120d 100644 --- a/tests/CSharp/CSharp.h +++ b/tests/CSharp/CSharp.h @@ -939,3 +939,15 @@ public: int conflictWithProperty(); virtual int getConflictWithProperty() = 0; }; + +template +class lowerCase +{ +}; + +class HasFieldsOfLowerCaseTemplate +{ +private: + lowerCase i; + lowerCase l; +};