[Kde-bindings] branches/KDE/4.4/kdebindings/generator/generators/smoke
Arno Rehn
kde at arnorehn.de
Fri Jan 29 17:33:09 UTC 2010
SVN commit 1082090 by arnorehn:
Generate default constructors for classes with pure virtuals, too.
CCMAIL: kde-bindings at kde.org
M +2 -2 helpers.cpp
--- branches/KDE/4.4/kdebindings/generator/generators/smoke/helpers.cpp #1082089:1082090
@@ -254,7 +254,7 @@
// The class can be instanciated if it has a public constructor or no constructor at all
// because then it has a default one generated by the compiler.
// If it has private pure virtuals, then it can't be instanciated either.
- bool ret = ((publicCtorFound || !ctorFound)/* && !privatePureVirtualsFound*/);
+ bool ret = ((publicCtorFound || !ctorFound) && !privatePureVirtualsFound);
cache[klass] = ret;
return ret;
}
@@ -386,7 +386,7 @@
{
foreach (const Method& meth, klass->methods()) {
// if the class already has a constructor or if it has pure virtuals, there's nothing to do for us
- if (meth.isConstructor() || meth.flags() & Method::PureVirtual)
+ if (meth.isConstructor())
return;
else if (meth.isDestructor() && meth.access() == Access_private)
return;
More information about the Kde-bindings
mailing list