summaryrefslogtreecommitdiffstats
path: root/generator/overloaddata.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'generator/overloaddata.cpp')
-rw-r--r--generator/overloaddata.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/generator/overloaddata.cpp b/generator/overloaddata.cpp
index c670209e..6bb06fe5 100644
--- a/generator/overloaddata.cpp
+++ b/generator/overloaddata.cpp
@@ -330,7 +330,8 @@ void OverloadData::sortNextOverloads()
graph.addEdge(targetTypeId, qvariantIndex);
} else if (checkQString && ov->argType()->indirections() > 0
&& targetTypeEntryName != "QString"
- && targetTypeEntryName != "QByteArray") {
+ && targetTypeEntryName != "QByteArray"
+ && (!checkPyObject || targetTypeId != pyobjectIndex)) {
if (!graph.containsEdge(qstringIndex, targetTypeId)) // Avoid cyclic dependency.
graph.addEdge(targetTypeId, qstringIndex);
}