aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorUlf Hermann <ulf.hermann@qt.io>2022-02-17 12:07:10 +0100
committerUlf Hermann <ulf.hermann@qt.io>2022-02-17 12:47:27 +0100
commit67347ab9644b9ec141277aa1f7cebcf1700544c9 (patch)
tree50365d6030e232c34af0a9033995b330e96aa0ad
parent68924be5b5282fb9f0276c743cf450f2e2aa5274 (diff)
QmlCompiler: Fix obscure build error
We only want to resolve the value type of the list at that point. It's certainly curious that it may not be part of the imports, but we can just force it to be the one we want. Change-Id: If390b7ebd870f375c54fa9b7b7110f0b32ca4fcb Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
-rw-r--r--src/qmlcompiler/qqmljstyperesolver.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/qmlcompiler/qqmljstyperesolver.cpp b/src/qmlcompiler/qqmljstyperesolver.cpp
index caa717f0fc..6de13a17a3 100644
--- a/src/qmlcompiler/qqmljstyperesolver.cpp
+++ b/src/qmlcompiler/qqmljstyperesolver.cpp
@@ -192,7 +192,8 @@ QQmlJSScope::ConstPtr QQmlJSTypeResolver::listType(const QQmlJSScope::ConstPtr &
listType->setValueTypeName(elementType->internalName());
listType->setInternalName(u"QList<%1>"_qs.arg(elementType->internalName()));
listType->setFileName(elementType->fileName());
- QQmlJSScope::resolveTypes(listType, m_imports);
+ const QQmlJSImportedScope element = {elementType, QTypeRevision()};
+ QQmlJSScope::resolveTypes(listType, {{elementType->internalName(), element}});
Q_ASSERT(equals(listType->valueType(), elementType));
m_typeTracker->listTypes[elementType] = listType;
return listType;