diff options
Diffstat (limited to 'sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp')
-rw-r--r-- | sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp b/sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp index b06376866..a2e2841df 100644 --- a/sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp +++ b/sources/shiboken2/ApiExtractor/abstractmetabuilder.cpp @@ -1258,9 +1258,7 @@ void AbstractMetaBuilderPrivate::fixReturnTypeOfConversionOperator(AbstractMetaF if (!retType) return; - auto *metaType = new AbstractMetaType; - metaType->setTypeEntry(retType); - metaFunction->replaceType(metaType); + metaFunction->replaceType(new AbstractMetaType(retType)); } AbstractMetaFunctionList AbstractMetaBuilderPrivate::classFunctionList(const ScopeModelItem &scopeItem, @@ -2010,8 +2008,7 @@ AbstractMetaType *AbstractMetaBuilderPrivate::translateType(const AddedFunction: } // These are only implicit and should not appear in code... - auto *metaType = new AbstractMetaType; - metaType->setTypeEntry(type); + auto *metaType = new AbstractMetaType(type); metaType->setIndirections(typeInfo.indirections); if (typeInfo.isReference) metaType->setReferenceType(LValueReference); @@ -2611,7 +2608,7 @@ bool AbstractMetaBuilderPrivate::inheritTemplate(AbstractMetaClass *subclass, const TypeInfo &info) { QVector<TypeInfo> targs = info.instantiations(); - QVector<AbstractMetaType *> templateTypes; + AbstractMetaTypeList templateTypes; QString errorMessage; if (subclass->isTypeDef()) { @@ -2654,8 +2651,7 @@ bool AbstractMetaBuilderPrivate::inheritTemplate(AbstractMetaClass *subclass, } if (t) { - auto *temporaryType = new AbstractMetaType; - temporaryType->setTypeEntry(t); + auto *temporaryType = new AbstractMetaType(t); temporaryType->setConstant(i.isConstant()); temporaryType->setReferenceType(i.referenceType()); temporaryType->setIndirectionsV(i.indirectionsV()); |