aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken2/generator/shiboken2
diff options
context:
space:
mode:
authorCristian Maureira-Fredes <cristian.maureira-fredes@qt.io>2018-01-15 16:48:24 +0100
committerCristian Maureira-Fredes <cristian.maureira-fredes@qt.io>2018-01-18 08:01:50 +0000
commit84db89c50e217db8811f20a58f959e82824d8338 (patch)
tree69f7436f45bce9e38941d3305636c8cbef43182c /sources/shiboken2/generator/shiboken2
parent84d46b89590c7e313aa4ab3edd9f8b0a4e913ae6 (diff)
Handle QObject-derived arguments correctly in constructor overload
Shiboken generated conditions to select which constructor overload needed to be used in an unexpected order. These conditions were incorrect, and hence produced an error. Handling QObjects in the inheritance relationship process solved the issue. Task-number: PYSIDE-203 Change-Id: Iee3a8c8fe48671cd752cc0e3d92b740c823656ad Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io>
Diffstat (limited to 'sources/shiboken2/generator/shiboken2')
-rw-r--r--sources/shiboken2/generator/shiboken2/overloaddata.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/sources/shiboken2/generator/shiboken2/overloaddata.cpp b/sources/shiboken2/generator/shiboken2/overloaddata.cpp
index 2b75b85be..3340ee957 100644
--- a/sources/shiboken2/generator/shiboken2/overloaddata.cpp
+++ b/sources/shiboken2/generator/shiboken2/overloaddata.cpp
@@ -323,7 +323,7 @@ void OverloadData::sortNextOverloads()
}
// Process inheritance relationships
- if (targetType->isValue() || targetType->isObject()) {
+ if (targetType->isValue() || targetType->isObject() || targetType->isQObject()) {
const AbstractMetaClass *metaClass = AbstractMetaClass::findClass(m_generator->classes(), targetType->typeEntry());
const AbstractMetaClassList &ancestors = m_generator->getAllAncestors(metaClass);
for (const AbstractMetaClass *ancestor : ancestors) {