aboutsummaryrefslogtreecommitdiffstats
path: root/sources/shiboken2/generator/shiboken2/shibokengenerator.cpp
diff options
context:
space:
mode:
authorRenato Araujo Oliveira Filho <renato.araujo@kdab.com>2020-10-06 09:49:18 -0300
committerRenato Araujo Oliveira Filho <renato.araujo@kdab.com>2020-10-21 16:26:39 -0300
commit24cd62c9d18850707574ba7eb637ff24bee353a1 (patch)
treeb0b7a84f6e9dc422bfbf973138f9cade773416c5 /sources/shiboken2/generator/shiboken2/shibokengenerator.cpp
parent85bb24c39df53ea61f59351a60f4284c32cb50ff (diff)
Update SmartPointers conversions
* Updated test to accept base types derived using std::shared_ptr; * Generate new coode to be able to convert smart pointers into shared pointers of base class. Functions that accepts SharedPointer<A> as argument should be able to accept SharedPointer<B> if B is derived from A. Task-number: PYSIDE-1397 Change-Id: I7e5235980daaf4651dad3ab1c880373f1c64e134 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'sources/shiboken2/generator/shiboken2/shibokengenerator.cpp')
-rw-r--r--sources/shiboken2/generator/shiboken2/shibokengenerator.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/sources/shiboken2/generator/shiboken2/shibokengenerator.cpp b/sources/shiboken2/generator/shiboken2/shibokengenerator.cpp
index 4ff3e8408..5d8685b90 100644
--- a/sources/shiboken2/generator/shiboken2/shibokengenerator.cpp
+++ b/sources/shiboken2/generator/shiboken2/shibokengenerator.cpp
@@ -860,7 +860,7 @@ QString ShibokenGenerator::converterObject(const AbstractMetaType *type)
+ QLatin1String(">(") + QString::number(nestedArrayTypes.size())
+ QLatin1Char(')');
}
- if (type->typeEntry()->isContainer()) {
+ if (type->typeEntry()->isContainer() || type->typeEntry()->isSmartPointer()) {
return convertersVariableName(type->typeEntry()->targetLangPackage())
+ QLatin1Char('[') + getTypeIndexVariableName(type) + QLatin1Char(']');
}