summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.cmake.conf1
-rw-r--r--src/qmlcompiler/qqmljsimporter.cpp2
-rw-r--r--src/qmlcompiler/qqmljsscope.cpp2
3 files changed, 3 insertions, 2 deletions
diff --git a/.cmake.conf b/.cmake.conf
index 83bf387c87..69f49dcc53 100644
--- a/.cmake.conf
+++ b/.cmake.conf
@@ -2,5 +2,6 @@ set(QT_REPO_MODULE_VERSION "6.5.0")
set(QT_REPO_MODULE_PRERELEASE_VERSION_SEGMENT "alpha1")
set(QT_EXTRA_INTERNAL_TARGET_DEFINES "QT_LEAN_HEADERS=1")
+list(APPEND QT_EXTRA_INTERNAL_TARGET_DEFINES "QT_NO_AS_CONST=1")
# Use cpp-based syncqt
set(QT_USE_SYNCQT_CPP TRUE)
diff --git a/src/qmlcompiler/qqmljsimporter.cpp b/src/qmlcompiler/qqmljsimporter.cpp
index a8fdc51ff5..731d24a5bc 100644
--- a/src/qmlcompiler/qqmljsimporter.cpp
+++ b/src/qmlcompiler/qqmljsimporter.cpp
@@ -485,7 +485,7 @@ void QQmlJSImporter::processImport(const QQmlJSScope::Import &importDescription,
}
}
- for (const auto &val : qAsConst(import.objects)) {
+ for (const auto &val : std::as_const(import.objects)) {
// Otherwise we have already done it in localFile2ScopeTree()
if (!val.scope.factory() && val.scope->baseType().isNull()) {
diff --git a/src/qmlcompiler/qqmljsscope.cpp b/src/qmlcompiler/qqmljsscope.cpp
index b1397981be..ec0a90643d 100644
--- a/src/qmlcompiler/qqmljsscope.cpp
+++ b/src/qmlcompiler/qqmljsscope.cpp
@@ -418,7 +418,7 @@ QQmlJSScope::ImportedScope<QQmlJSScope::ConstPtr> QQmlJSScope::findType(
if (outerType == contextualTypes.types().constEnd())
break;
- for (const auto &innerType : qAsConst(outerType->scope->m_childScopes)) {
+ for (const auto &innerType : std::as_const(outerType->scope->m_childScopes)) {
if (innerType->m_internalName == name) {
useType();
return { innerType, outerType->revision };