summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2011-04-27 15:04:28 -0300
committerHugo Parente Lima <hugo.pl@gmail.com>2011-04-27 17:14:55 -0300
commit5962d2a1c39e9446f89911cc20b2b6e61e0b6a04 (patch)
tree6e3174d61ce088c72ebbcd15d3cd467aa601b59c
parentc42a025c622fdfb8e7765806c07153c7712a2e5f (diff)
downloadshiboken-5962d2a1c39e9446f89911cc20b2b6e61e0b6a04.tar.gz
shiboken-5962d2a1c39e9446f89911cc20b2b6e61e0b6a04.tar.xz
shiboken-5962d2a1c39e9446f89911cc20b2b6e61e0b6a04.zip
Don't create cyclic graphs when there are QString, PySequence and PyObjects involved into a single overload.1.0.2
Reviewer: Renato Ara├║jo <renato.filho@openbossa.org> Marcelo Lira <marcelo.lira@openbossa.org>
-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);
}