From c5ffcd673f5fca4f9af96f92a0184ce287599a0f Mon Sep 17 00:00:00 2001 From: Dimitri van Heesch Date: Thu, 24 Dec 2020 15:01:53 +0100 Subject: issue #8050: Artificial classDef confuses getCanonicalTypeForIdentifier() --- src/doxygen.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/doxygen.cpp b/src/doxygen.cpp index 0f06d8f..9b3dcb0 100644 --- a/src/doxygen.cpp +++ b/src/doxygen.cpp @@ -753,6 +753,7 @@ static Definition *buildScopeFromQualifiedName(const QCString name, tagInfo?tagInfo->tagName:QCString(), tagInfo?tagInfo->fileName:QCString())))); newNd->setLanguage(lang); + newNd->setArtificial(TRUE); // add namespace to the list innerScope = newNd; @@ -4512,6 +4513,7 @@ static bool findClassRelation( ClassDef::Class)))); if (isArtificial) baseClass->setArtificial(TRUE); baseClass->setLanguage(root->lang); + } } else @@ -4550,7 +4552,10 @@ static bool findClassRelation( baseClass->insertSubClass(cd,bi->prot,bi->virt,templSpec); // the undocumented base was found in this file baseClass->insertUsedFile(root->fileDef()); - baseClass->setOuterScope(Doxygen::globalScope); + + Definition *scope = buildScopeFromQualifiedName(baseClass->name(),baseClass->name().contains("::"),root->lang,0); + baseClass->setOuterScope(scope); + if (baseClassName.right(2)=="-p") { baseClass->setCompoundType(ClassDef::Protocol); -- cgit v0.12