From 3c5fa29f78816d8cc7fd9fa6e9462e2a9f283f64 Mon Sep 17 00:00:00 2001 From: Topi Reinio Date: Tue, 21 Jun 2016 11:59:13 +0200 Subject: qdoc: Improve resolution of QML type inheritance QDoc maintains a global map of base types for all QML types. This caused issues whenever QML modules have conflicting type names; for example, types from Qt Quick Controls (v1) were incorrectly marked as deriving from QQC v2 'Control' type. To improve the situation, make following changes: - Manage 'inherited by' map in a single location. Types are added to this map in a pre-generate step (QDocDatabase::resolveQmlInheritance()) after parsing all sources. This allows better control of searching - if the QML type node has an import list, the search is now always based on it. - Add a safeguard against using a base type from a module with major version different to the import statement. - Use node pointers as keys in 'Inherited by' map, instead of type-name strings. Task-number: QTBUG-53529 Change-Id: I6665a520c9197fa90e84d67b12e3405b5b3f0901 Reviewed-by: Mitch Curtis Reviewed-by: Martin Smith --- src/qdoc/cppcodeparser.cpp | 1 - 1 file changed, 1 deletion(-) (limited to 'src/qdoc/cppcodeparser.cpp') diff --git a/src/qdoc/cppcodeparser.cpp b/src/qdoc/cppcodeparser.cpp index 5b7792d32..57cd1e917 100644 --- a/src/qdoc/cppcodeparser.cpp +++ b/src/qdoc/cppcodeparser.cpp @@ -970,7 +970,6 @@ void CppCodeParser::processOtherMetaCommand(const Doc& doc, else if (node->isQmlType() || node->isJsType()) { QmlTypeNode* qmlType = static_cast(node); qmlType->setQmlBaseName(arg); - QmlTypeNode::addInheritedBy(arg,node); } } else if (command == COMMAND_QMLINSTANTIATES) { -- cgit v1.2.1