diff options
author | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-04-09 01:01:06 +0200 |
---|---|---|
committer | Qt Forward Merge Bot <qt_forward_merge_bot@qt-project.org> | 2019-04-09 01:01:07 +0200 |
commit | 8c3172d724f3ad03cdee7bae23443fa109d350b1 (patch) | |
tree | 53ad546936e22b99d1ea395a875a312332d05516 /src/qml | |
parent | 5a5441f38e0529d852536b776cd9f26dad410e62 (diff) | |
parent | 4b6832828e04a9806aaf345da5f456817dd3970b (diff) |
Merge remote-tracking branch 'origin/5.12' into 5.13v5.13.0-beta2
Change-Id: I68211a7d4568a1c31c6a124fe6777709c53736a5
Diffstat (limited to 'src/qml')
-rw-r--r-- | src/qml/jsruntime/qv4internalclass_p.h | 2 | ||||
-rw-r--r-- | src/qml/jsruntime/qv4runtime.cpp | 1 | ||||
-rw-r--r-- | src/qml/types/qqmlmodelsmodule.cpp | 2 |
3 files changed, 4 insertions, 1 deletions
diff --git a/src/qml/jsruntime/qv4internalclass_p.h b/src/qml/jsruntime/qv4internalclass_p.h index 42b61218a5..7bb10f47a3 100644 --- a/src/qml/jsruntime/qv4internalclass_p.h +++ b/src/qml/jsruntime/qv4internalclass_p.h @@ -457,7 +457,7 @@ private: InternalClass *addMemberImpl(PropertyKey identifier, PropertyAttributes data, InternalClassEntry *entry); void removeChildEntry(InternalClass *child); - friend struct ExecutionEngine; + friend struct ::QV4::ExecutionEngine; }; inline diff --git a/src/qml/jsruntime/qv4runtime.cpp b/src/qml/jsruntime/qv4runtime.cpp index 3e9e972d77..f7c339dc26 100644 --- a/src/qml/jsruntime/qv4runtime.cpp +++ b/src/qml/jsruntime/qv4runtime.cpp @@ -1990,6 +1990,7 @@ ReturnedValue Runtime::method_div(const Value &left, const Value &right) int lval = left.integerValue(); int rval = right.integerValue(); if (rval != 0 // division by zero should result in a NaN + && !(lval == std::numeric_limits<int>::min() && rval == -1) // doesn't fit in int && (lval % rval == 0) // fractions can't be stored in an int && !(lval == 0 && rval < 0)) // 0 / -something results in -0.0 return Encode(int(lval / rval)); diff --git a/src/qml/types/qqmlmodelsmodule.cpp b/src/qml/types/qqmlmodelsmodule.cpp index 30915d96fd..bb72771cd9 100644 --- a/src/qml/types/qqmlmodelsmodule.cpp +++ b/src/qml/types/qqmlmodelsmodule.cpp @@ -72,9 +72,11 @@ void QQmlModelsModule::defineLabsModule() { const char uri[] = "Qt.labs.qmlmodels"; +#if QT_CONFIG(qml_delegate_model) qmlRegisterUncreatableType<QQmlAbstractDelegateComponent>(uri, 1, 0, "AbstractDelegateComponent", QQmlAbstractDelegateComponent::tr("Cannot create instance of abstract class AbstractDelegateComponent.")); qmlRegisterType<QQmlDelegateChooser>(uri, 1, 0, "DelegateChooser"); qmlRegisterType<QQmlDelegateChoice>(uri, 1, 0, "DelegateChoice"); +#endif } QT_END_NAMESPACE |