diff options
author | Brett Stottlemyer <bstottle@ford.com> | 2021-02-13 15:19:49 -0500 |
---|---|---|
committer | Brett Stottlemyer <bstottle@ford.com> | 2021-02-15 14:15:00 -0500 |
commit | 8fcc330ac5bbe1dc7faa72a2343f82d47ffb41fa (patch) | |
tree | 6e9891da2442d2be6613056a55d53cc3b8830f4e /tools | |
parent | 306edc01e133bd3addf219923a9bb755cdda57e9 (diff) |
Fix QMetaType Deprecation warnings
Change-Id: If7de5da3e7ad6d345e8b483486bb7177bccbc0df
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Diffstat (limited to 'tools')
-rw-r--r-- | tools/repc/repcodegenerator.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tools/repc/repcodegenerator.cpp b/tools/repc/repcodegenerator.cpp index f27346a..ea2d42c 100644 --- a/tools/repc/repcodegenerator.cpp +++ b/tools/repc/repcodegenerator.cpp @@ -105,10 +105,10 @@ static QVector<ASTFunction> transformEnumParams(const ASTClass& classContext, co */ static bool isBuiltinType(const QString &type) { - int id = QMetaType::type(type.toLatin1().constData()); - if (id == QMetaType::UnknownType) + const auto metaType = QMetaType::fromName(type.toLatin1().constData()); + if (!metaType.isValid()) return false; - return (id < QMetaType::User); + return (metaType.id() < QMetaType::User); } RepCodeGenerator::RepCodeGenerator(QIODevice *outputDevice) |