Browse Source

Fixed a couple of places where privates that need to be generated were being filtered.

pull/304/head
Tom Spilman 12 years ago
parent
commit
0f8977ec91
  1. 2
      src/Generator/AST/Utils.cs
  2. 2
      src/Generator/Passes/CheckIgnoredDecls.cs

2
src/Generator/AST/Utils.cs

@ -36,7 +36,7 @@ namespace CppSharp.AST @@ -36,7 +36,7 @@ namespace CppSharp.AST
if (method.OperatorKind == CXXOperatorKind.Equal)
return true;
if (method.Access == AccessSpecifier.Private && !method.IsOverride)
if (method.Access == AccessSpecifier.Private && !method.IsOverride && !method.IsExplicitlyGenerated)
return true;
//Ignore copy constructor if a base class don't has or has a private copy constructor

2
src/Generator/Passes/CheckIgnoredDecls.cs

@ -23,7 +23,7 @@ namespace CppSharp.Passes @@ -23,7 +23,7 @@ namespace CppSharp.Passes
case AccessSpecifier.Private:
var method = decl as Method;
var isOverride = method != null && method.IsOverride;
return generateNonPublicDecls && isOverride;
return generateNonPublicDecls && (isOverride || decl.IsExplicitlyGenerated);
}
return true;

Loading…
Cancel
Save