diff options
author | Olivier Goffart <olivier.goffart@nokia.com> | 2010-06-30 13:52:20 (GMT) |
---|---|---|
committer | Olivier Goffart <olivier.goffart@nokia.com> | 2010-06-30 15:27:27 (GMT) |
commit | 01648005f1f546dc0281155fecd94b4f47a94584 (patch) | |
tree | 4ab00c221ba86cb4f977b8cda73d469389868d9f /tests/auto/qmetaobject | |
parent | 7d80cd1f66fa6331c926674870d2a0dbe2921e77 (diff) | |
download | Qt-01648005f1f546dc0281155fecd94b4f47a94584.zip Qt-01648005f1f546dc0281155fecd94b4f47a94584.tar.gz Qt-01648005f1f546dc0281155fecd94b4f47a94584.tar.bz2 |
Moc: fix compilation when templated types with multiple arguments are used.
Each template argument need to be normalized separately. Else, the const
type of one argument may end up moved in the first argument.
(And then the compilation of the generated moc file would fail as the types
would not match)
Reviewed-by: Kent Hansen
Task-number: QTBUG-11647
Diffstat (limited to 'tests/auto/qmetaobject')
-rw-r--r-- | tests/auto/qmetaobject/tst_qmetaobject.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/qmetaobject/tst_qmetaobject.cpp b/tests/auto/qmetaobject/tst_qmetaobject.cpp index b6d4558..62416b1 100644 --- a/tests/auto/qmetaobject/tst_qmetaobject.cpp +++ b/tests/auto/qmetaobject/tst_qmetaobject.cpp @@ -740,6 +740,8 @@ void tst_QMetaObject::normalizedType_data() QTest::newRow("template5") << "QList< ::Foo::Bar>" << "QList< ::Foo::Bar>"; QTest::newRow("template6") << "QList<::Foo::Bar>" << "QList<::Foo::Bar>"; QTest::newRow("template7") << "QList<QList<int> >" << "QList<QList<int> >"; + QTest::newRow("template8") << "QMap<const int, const short*>" << "QMap<const int,const short*>"; + QTest::newRow("template9") << "QPair<const QPair<int, int const *> , QPair<QHash<int, const char*> > >" << "QPair<const QPair<int,const int*>,QPair<QHash<int,const char*> > >"; QTest::newRow("value1") << "const QString &" << "QString"; QTest::newRow("value2") << "QString const &" << "QString"; QTest::newRow("constInName1") << "constconst" << "constconst"; |