summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--abstractmetabuilder.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/abstractmetabuilder.cpp b/abstractmetabuilder.cpp
index 780ea700..ea1fed6b 100644
--- a/abstractmetabuilder.cpp
+++ b/abstractmetabuilder.cpp
@@ -2778,6 +2778,10 @@ AbstractMetaClassList AbstractMetaBuilder::classesTopologicalSorted(const Abstra
AbstractMetaClassList bases = getBaseClasses(clazz);
foreach(AbstractMetaClass* baseClass, bases) {
+ // Fix polymorphic expression
+ if (clazz->baseClass() == baseClass)
+ clazz->setBaseClass(baseClass);
+
if (map.contains(baseClass->qualifiedCppName()))
graph.addEdge(map[baseClass->qualifiedCppName()], map[clazz->qualifiedCppName()]);
}