aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@qt.io>2018-07-03 09:02:10 +0200
committerFriedemann Kleint <Friedemann.Kleint@qt.io>2018-07-04 07:08:31 +0000
commite729091759156f417d987ede9de8961d33f28079 (patch)
tree4738997fa3b02bdeda51d3e1f2a2a5eb24184599
parent5cd52cda24bf70bf99f4deec037039df0ab928f5 (diff)
shiboken: Extend debug operators
Output template arguments of TypeEntry/AbstractMetaType. Task-number: PYSIDE-672 Change-Id: Ib7e161c8313f91a540659c395a8684498e86aba2 Reviewed-by: Christian Tismer <tismer@stackless.com>
-rw-r--r--sources/shiboken2/ApiExtractor/abstractmetalang.cpp22
1 files changed, 22 insertions, 0 deletions
diff --git a/sources/shiboken2/ApiExtractor/abstractmetalang.cpp b/sources/shiboken2/ApiExtractor/abstractmetalang.cpp
index 5be7050bf..849c805db 100644
--- a/sources/shiboken2/ApiExtractor/abstractmetalang.cpp
+++ b/sources/shiboken2/ApiExtractor/abstractmetalang.cpp
@@ -301,6 +301,16 @@ QDebug operator<<(QDebug d, const AbstractMetaType *at)
d << ", array of \"" << at->arrayElementType()->cppSignature()
<< "\", arrayElementCount=" << at->arrayElementCount();
}
+ const auto &instantiations = at->instantiations();
+ if (const int instantiationsSize = instantiations.size()) {
+ d << ", instantiations[" << instantiationsSize << "]=<";
+ for (int i = 0; i < instantiationsSize; ++i) {
+ if (i)
+ d << ", ";
+ d << instantiations.at(i);
+ }
+ }
+ d << '>';
}
} else {
d << '0';
@@ -2406,6 +2416,18 @@ QDebug operator<<(QDebug d, const AbstractMetaClass *ac)
}
d << ')';
}
+ const auto &templateArguments = ac->templateArguments();
+ if (const int count = templateArguments.size()) {
+ d << ", templateArguments=[" << count << "](";
+ for (int i = 0; i < count; ++i) {
+ if (i)
+ d << ", ";
+ d << templateArguments.at(i);
+ }
+ d << ')';
+ }
+
+
} else {
d << '0';
}