Browse Source

Fixed a regression causing ignored types with bases without empty ctors to fail.

Signed-off-by: Dimitar Dobrev <dpldobrev@yahoo.com>
pull/361/head
Dimitar Dobrev 11 years ago
parent
commit
b9042d72b5
  1. 2
      src/Generator/Generators/CSharp/CSharpTextTemplate.cs
  2. 2
      tests/CSharpTemp/CSharpTemp.cs
  3. 5
      tests/CSharpTemp/CSharpTemp.h

2
src/Generator/Generators/CSharp/CSharpTextTemplate.cs

@ -744,7 +744,7 @@ namespace CppSharp.Generators.CSharp @@ -744,7 +744,7 @@ namespace CppSharp.Generators.CSharp
var bases = new List<string>();
var needsBase = @class.HasGeneratedBase;
var needsBase = @class.HasGeneratedBase && @class.IsGenerated;
if (needsBase)
{

2
tests/CSharpTemp/CSharpTemp.cs

@ -82,6 +82,8 @@ namespace CppSharp.Tests @@ -82,6 +82,8 @@ namespace CppSharp.Tests
{
ctx.SetClassAsValueType("TestCopyConstructorVal");
ctx.SetClassAsValueType("QGenericArgument");
ctx.IgnoreClassWithName("IgnoredTypeInheritingNonIgnoredWithNoEmptyCtor");
}
public override void Postprocess(Driver driver, ASTContext ctx)

5
tests/CSharpTemp/CSharpTemp.h

@ -20,6 +20,7 @@ public: @@ -20,6 +20,7 @@ public:
Qux();
Qux(Foo foo);
int farAwayFunc() const;
int array[3];
void obsolete();
};
@ -253,6 +254,10 @@ class DLL_API IgnoredType @@ -253,6 +254,10 @@ class DLL_API IgnoredType
{
};
class DLL_API IgnoredTypeInheritingNonIgnoredWithNoEmptyCtor : public P
{
};
class DLL_API PropertyWithIgnoredType
{
public:

Loading…
Cancel
Save