aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@qt.io>2017-05-31 08:12:24 +0200
committerLiang Qi <liang.qi@qt.io>2017-05-31 08:12:25 +0200
commit9f178cbe9ea27d247c82c7bbc396b1c3b264a06d (patch)
tree552cc5682fef1d046e9ad9394a22620bd380ad98 /src/qml
parent344fbc3d2f4ccc9773e2bbe7b2969b4ac86dc9aa (diff)
parent96f6ba5f562073f508cd8569ac354592fdd48f4a (diff)
Merge remote-tracking branch 'origin/5.9.0' into 5.9
Diffstat (limited to 'src/qml')
-rw-r--r--src/qml/compiler/qqmlirbuilder.cpp5
-rw-r--r--src/qml/qtqmlglobal.h16
-rw-r--r--src/qml/qtqmlglobal_p.h4
3 files changed, 15 insertions, 10 deletions
diff --git a/src/qml/compiler/qqmlirbuilder.cpp b/src/qml/compiler/qqmlirbuilder.cpp
index 9f2c2294ed..16eee50cf9 100644
--- a/src/qml/compiler/qqmlirbuilder.cpp
+++ b/src/qml/compiler/qqmlirbuilder.cpp
@@ -1924,7 +1924,7 @@ QV4::IR::Expr *JSCodeGen::fallbackNameLookup(const QString &name, int line, int
// with the correct QML context.
// Look for IDs first.
- for (const IdMapping &mapping : qAsConst(_idObjects))
+ for (const IdMapping &mapping : qAsConst(_idObjects)) {
if (name == mapping.name) {
if (_function->isQmlBinding)
_function->idObjectDependencies.insert(mapping.idIndex);
@@ -1942,8 +1942,9 @@ QV4::IR::Expr *JSCodeGen::fallbackNameLookup(const QString &name, int line, int
result->isReadOnly = true; // don't allow use as lvalue
return result;
}
+ }
- {
+ if (name.at(0).isUpper()) {
QQmlTypeNameCache::Result r = imports->query(name);
if (r.isValid()) {
if (r.scriptIndex != -1) {
diff --git a/src/qml/qtqmlglobal.h b/src/qml/qtqmlglobal.h
index 6704e55b52..387c28a945 100644
--- a/src/qml/qtqmlglobal.h
+++ b/src/qml/qtqmlglobal.h
@@ -40,18 +40,20 @@
#ifndef QTQMLGLOBAL_H
#define QTQMLGLOBAL_H
+#if defined(QT_BUILD_QMLDEVTOOLS_LIB) || defined(QT_QMLDEVTOOLS_LIB)
+# define QT_QML_BOOTSTRAPPED
+#endif
+
#include <QtCore/qglobal.h>
-#include <QtQml/qtqml-config.h>
-#if QT_CONFIG(qml_network)
-#include <QtNetwork/qtnetworkglobal.h>
+#ifndef QT_QML_BOOTSTRAPPED
+# include <QtQml/qtqml-config.h>
+# if QT_CONFIG(qml_network)
+# include <QtNetwork/qtnetworkglobal.h>
+# endif
#endif
QT_BEGIN_NAMESPACE
-#if defined(QT_BUILD_QMLDEVTOOLS_LIB) || defined(QT_QMLDEVTOOLS_LIB)
-# define QT_QML_BOOTSTRAPPED
-#endif
-
#if !defined(QT_QML_BOOTSTRAPPED) && !defined(QT_STATIC)
# if defined(QT_BUILD_QML_LIB)
# define Q_QML_EXPORT Q_DECL_EXPORT
diff --git a/src/qml/qtqmlglobal_p.h b/src/qml/qtqmlglobal_p.h
index 3314e73d19..4c0ba338d8 100644
--- a/src/qml/qtqmlglobal_p.h
+++ b/src/qml/qtqmlglobal_p.h
@@ -52,8 +52,10 @@
//
#include <QtCore/private/qglobal_p.h>
-#include <QtQml/private/qtqml-config_p.h>
#include <QtQml/qtqmlglobal.h>
+#ifndef QT_QML_BOOTSTRAPPED
+# include <QtQml/private/qtqml-config_p.h>
+#endif
#define Q_QML_PRIVATE_EXPORT Q_QML_EXPORT