diff options
Diffstat (limited to 'cppgenerator.cpp')
-rw-r--r-- | cppgenerator.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/cppgenerator.cpp b/cppgenerator.cpp index 369ee409d..c899a4697 100644 --- a/cppgenerator.cpp +++ b/cppgenerator.cpp @@ -568,12 +568,12 @@ void CppGenerator::writeVirtualMethodNative(QTextStream &s, const AbstractMetaFu } s << INDENT << '}' << endl; - if (func->type() && (!usePySideExtensions() || (func->type()->name() != "QVariant"))) { + if (func->type()) { s << INDENT << "// Check return type" << endl; s << INDENT << "bool typeIsValid = "; QString desiredType; if (func->typeReplaced(0).isEmpty()) { - s << cpythonCheckFunction(func->type()); + s << cpythonIsConvertibleFunction(func->type()); // SbkType would return null when the type is a container. if (func->type()->typeEntry()->isContainer()) { desiredType = '"' + reinterpret_cast<const ContainerTypeEntry*>(func->type()->typeEntry())->typeName() + '"'; |