aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml
Commit message (Collapse)AuthorAgeFilesLines
...
| | * Don't call unknown types "null"Ulf Hermann2019-04-261-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | That is rather confusing. Task-number: QTBUG-74815 Change-Id: Id683a7f9efd63c8859c5740ceab9f161cea46ee3 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Fix maximum call stack depth limits for ASAN buildsSimon Hausmann2019-04-261-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ASAN enabled builds require more stack space and therefore our call depth limits should be lower. In my measurements with a recursion through arrow functions with the interpreter, as per the test case in the bug report, different types of builds require different amounts of stack space. On x86-64 Linux, I measured, by printing $rsp and subtracting: Debug: ~6k Debug with -Og: ~590 bytes Release with -O2: ~570 bytes Release (-O2) with ASAN: ~40k Fixes: QTBUG-75410 Change-Id: I403b261c677b1adb9f349958339b5a1294ae4d5d Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * Fix crash in QQmlMetaType::freeUnusedTypesAndCaches()Kevin Funk2019-04-251-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix crash when QQmlMetaType::freeUnusedTypesAndCaches() is being called during program exit, i.e. when the parent QJSEngine instance is being destructed during exit(). Sample backtrace: #0 QQmlMetaType::freeUnusedTypesAndCaches () at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/qml/qqmlmetatype.cpp:2600 #1 0x00007fffe12fce83 in QJSEnginePrivate::~QJSEnginePrivate (this=0x60c001c0b040, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:982 #2 0x00007fffe12fce9f in QJSEnginePrivate::~QJSEnginePrivate (this=0x60c001c0b040, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:980 #3 0x00007ffff53650c3 in QScopedPointerDeleter<QObjectData>::cleanup (pointer=<optimized out>) at ../../include/QtCore/../../../../../src/qt5.12/qtbase/src/corelib/tools/qscopedpointer.h:52 #4 QScopedPointer<QObjectData, QScopedPointerDeleter<QObjectData> >::~QScopedPointer (this=0x60300178b3a8, __in_chrg=<optimized out>) at ../../include/QtCore/../../../../../src/qt5.12/qtbase/src/corelib/tools/qscopedpointer.h:107 #5 QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:891 #6 0x00007fffe12ff572 in QJSEngine::~QJSEngine (this=0x60300178b3a0, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:379 #7 0x00007fffe12ff583 in QJSEngine::~QJSEngine (this=0x60300178b3a0, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtdeclarative/src/qml/jsapi/qjsengine.cpp:375 #8 0x00007ffff5363cc4 in QObjectPrivate::deleteChildren (this=this@entry=0x60b00016c380) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:2010 #9 0x00007ffff53650f5 in QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:1032 #10 0x00007fffe103b43b in Grantlee::ScriptableTagLibrary::~ScriptableTagLibrary (this=0x607000ba4c00) at templates/lib/Grantlee_Templates_autogen/MTDBPGIEEV/../../../../../../../src/kf5/grantlee/templates/scriptabletags/scriptabletags.h:58 #11 0x00007fffe103b469 in Grantlee::ScriptableTagLibrary::~ScriptableTagLibrary (this=0x607000ba4c00) at templates/lib/Grantlee_Templates_autogen/MTDBPGIEEV/../../../../../../../src/kf5/grantlee/templates/scriptabletags/scriptabletags.h:58 #12 0x00007ffff5363cc4 in QObjectPrivate::deleteChildren (this=this@entry=0x60b00016c0c0) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:2010 #13 0x00007ffff53650f5 in QObject::~QObject (this=<optimized out>, __in_chrg=<optimized out>) at /home/kfunk/devel/src/qt5.12/qtbase/src/corelib/kernel/qobject.cpp:1032 #14 0x00007fffe0fef704 in Grantlee::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantlee/templates/lib/engine.cpp:60 #15 0x00007fffdf2e2482 in GrantleeTheme::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantleetheme/src/grantleethemeengine.cpp:54 #16 0x00007fffdf2e24a9 in GrantleeTheme::Engine::~Engine (this=0x60300178a2c0) at /home/kfunk/devel/src/kf5/grantleetheme/src/grantleethemeengine.cpp:52 #17 0x00007ffff3f4f8d1 in MessageViewer::MessagePartRendererManager::~MessagePartRendererManager (this=0x7ffff40c8ab0 <MessageViewer::MessagePartRendererManager::self()::s_self>) at /home/kfunk/devel/src/kf5/messagelib/messageviewer/src/messagepartthemes/default /messagepartrenderermanager.cpp:118 #18 0x00007ffff4b442ac in ?? () from /lib/x86_64-linux-gnu/libc.so.6 #19 0x00007ffff4b443da in exit () from /lib/x86_64-linux-gnu/libc.so.6 Also see: https://bugs.kde.org/show_bug.cgi?id=406871 Change-Id: If5676880c87f1fa2405701a439e1a0037dce045c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * | Fix compile error with qml_tracing enabledUlf Hermann2019-04-261-1/+1
| | | | | | | | | | | | | | | | | | | | | "hasTry" doesn't exist. Change-Id: Ia6df66406e296c7623fa872ef32acc46d93b3319 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-251-12/+1
| |\| | | | | | | | | | Change-Id: I2fea101de38922d34088c6eca0e256ec167ad118
| | * Revert "Optimize some Lookups"Michal Klocek2019-04-241-12/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 2beb77c81a1f3585c15099a09ba8b2192c6da824. To optimize lookup in case of heapObject we cast its value to Object. This unfortunately does not work well when the value type of heap object is actually a string. Task-number: QTBUG-75335 Change-Id: I55d7c9e0d41f3be617ca7141a4121de3a56f8eef Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Tooling: Use fprintf rather than qDebug() for debug warningUlf Hermann2019-04-241-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This warning is generated from a statically called ctor. At that point the system facilities to run QMessageLogger may not be in place, yet. In addition, we actually don't want the message to go through the regular QMessageLogger redirection and possibly filtering. The message should always be shown. Fixes: QTBUG-73217 Change-Id: Ief192dae8c38d5d94996ee9285e54b5cbd714f4b Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> (cherry-picked from commit 15525d2a309a6028d548797bc777e38905f36c46)
* | | Fix line number precision for a binding's expressionIdentifierErik Verbruggen2019-04-261-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | Location::line is 20 bits, so assigning it to a 16 unsigned integer truncates the number unnecessarily. Change-Id: I50a7ec73d6a88505c7d41b5a2b7ceb726b9dd437 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Transform V4_ENABLE_JIT into a featureUlf Hermann2019-04-2513-69/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This way you can enable or disable the JIT when configuring Qt. The conditions for the availability of the JIT have also been cleaned up. There is no reason anymore to artificially restrict availability on x86 and x86_64. The reason for the existence of those clauses are old problems on windows that have been fixed by now. However, on arm and arm64, we need a specialization of the cacheFlush() function for each OS to be supported. Therefore, restrict to the systems for which such a specialization exists. iOS and tvOS are technically supported and you can enable the JIT via the feature flag now. Due to Apple's policy we disable it by default, though. Change-Id: I5fe2a2bf6799b2d11b7ae7c7a85962bcbf44f919 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Move creation and management of singletons to QQmlEnginePrivateRichard Weickelt2019-04-247-194/+184
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Singleton object instances were previously managed by QQmlType::SingletonInstanceInfo and kept in a shared storage. This caused concurrency problems when instantiating singleton instances from different QML engines in different threads. This patch moves the singleton house-keeping infrastructure to QQmlEnginePrivate and makes SingletonInstanceInfo immutable. Singleton objects are stored in a QHash with QQmlType as the key because the qml type id might be 0 for composite singletons. The public API of QQmlType is extended to provide more information about singleton types so that access to SingletonInstanceInfo is not needed. All internal accesses of singleton objects must now take the same code path via QQmlEnginePrivate::singletonInstance<T>() which simplifies overall usage of singletons and scatters less implementation details throughout the code base. Task-number: QTBUG-75007 Change-Id: I13c5fd21cac2eb7291f2cbcf2c2b504f0f51a07c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-2313-71/+82
|\| | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlmetatype.cpp Change-Id: Ieff61c076e46eb50a059c8b0210f7f4d7ce0cbcf
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-1910-47/+84
| |\| | | | | | | | | | Change-Id: I9ef4be23bfe35aa48d4c65d4159e72c527943845
| | * QML: Remove static attchedPropertyIds mapUlf Hermann2019-04-189-46/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the same object is available under two different names it should still have the same attached properties no matter which name you use. This was achieved by having a static map of metaobjects to attached property IDs that would always hold the first attached property ID registered for a given metaobject. This attached property ID was then used as key in the map of attached properties for the actual objects. The obvious downside to that is that we need a global static which gives us thread safety and static initialization (and destruction) problems. It turns out, all the attached properties are created by attached properties functions, registered by the user. Those functions only get the object to be amended as parameter. Therefore, no attached properties function can be registered for multiple attached properties on the same object as it wouldn't know which one to create for a given call. Thus, the whole ID dance is unnecessary as we can as well index the attached property objects by the function that created them. This nicely avoids creating two attached property objects for the same object and function and still makes the global static unnecessary. Fixes: QTBUG-75176 Change-Id: Ie8d53ef0a6f41c9b3d6b9d611cde1603a557901c Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
| | * Don't crash when accessing invalid properties through QObjectWrapperUlf Hermann2019-04-181-1/+1
| | | | | | | | | | | | | | | | | | Change-Id: I613bf5dc685bb4235262b429d8f7318ea144fb9d Fixes: QTBUG-75203 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Deduplicate QQmlPropertyCache::l{azyL}oadUlf Hermann2019-04-211-40/+16
| | | | | | | | | | | | | | | Change-Id: I0ca6d168abc076f93405791059db73667afa6009 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Don't needlessly restrict Qt.include() in case !qml-networkUlf Hermann2019-04-181-8/+5
| | | | | | | | | | | | | | | Change-Id: I1cc23941121a5b2b16e94fc46e48bdce1f452afb Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Dissolve QQmlPropertyRawDataLars Knoll2019-04-186-401/+308
| | | | | | | | | | | | | | | | | | | | | There is no reason anymore to split the class in two parts. Change-Id: Iabef7acec1db7afc0ed4e89e1fd5b78699dc0847 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Move propertyCache-by-minor-version into QQmlMetaTypeDataUlf Hermann2019-04-187-38/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ths data structure should only be accessed when protected by the metatype data lock. In fact we don't access it from anywhere else. To make that more obvious, move it to the right place. This allows us to eliminate some const_cast and poking around in QQmlTypePrivate from the outside. Change-Id: I16ffd240b9504b9c00010bdb2d17b05c8196fe8a Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Clean up type registrationUlf Hermann2019-04-185-73/+81
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The QML-specific types need to be registered only for "QtQml". Make sure we don't accidentally add new QML-specific types to QtQuick. We also don't want the base types to be registered under any random URI and version. Formally qmlRegisterBaseTypes() is a public function, but it _really_ should not be called by anyone. Finally, split the types into ones that should belong to QtQml.Models and ones that belong to QtQml proper. Add a plugin that handles QtQml itself rather than using the QQmlEngine ctor for this. [ChangeLog] The accidentally exported function qmlRegisterBaseTypes() was removed. Change-Id: I8bf9f8515e18b016750c721fe694d4cda076780b Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Drop some dead QT_CONFIG conditionsUlf Hermann2019-04-181-4/+0
| | | | | | | | | | | | | | | | | | | | | The file is not compiled at all if !qml-xml-http-request. Change-Id: If3d3d00f195e6bd8bd2af9cff247f31c918ab0c8 Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-1811-42/+82
|\| | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlimport.cpp Change-Id: I6add6267297ea50a646d43d212027a168dca8916
| * | Improve error messageRainer Keller2019-04-171-1/+4
| | | | | | | | | | | | | | | Change-Id: I1f7f0781521757f5412b50680203698e33bd9d23 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-177-18/+22
| |\| | | | | | | | | | | | | | | | | | | Conflicts: tests/auto/qml/qv4assembler/tst_qv4assembler.cpp Change-Id: I9d31c982881a617099354bf8acceb76332f11496
| | * V4: Only enable the JIT on ARM on specific known OSesMartin Storsjö2019-04-161-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On all other architectures, the JIT is only enabled for explicitly mentioned OSes. This fixes build errors for Windows on 32 bit ARM, about the cacheFlush function being unimplemented for that target. This keeps all other OSes enabled that are mentioned in conditionals for other architectures, except for windows. Change-Id: I8c29a9399a05a57d23b4fee506c3d04859a08a76 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * QML: Allow fetchOrCreateTypeForUrl to report errors without qFatalErik Verbruggen2019-04-161-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Because qFatal will abort() the program. Task-number: QTBUG-71116 Change-Id: Ifd6be996cfbd6fff8e75ad2b26682c34f837ac88 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * QML: Check for (valid) compilation units while hashingErik Verbruggen2019-04-161-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | When an error occurred while creating a compilation unit, the pointer might be set to null. Subsequent use in hashing should check for this, and not use a nullptr. Change-Id: I62650917a740c9c1be29608285670153bed8703c Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * QMLJS: Remove unused boolean field hasTry from compiler contextErik Verbruggen2019-04-151-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | All uses have been refactored out in previous commits, so now also remove the field. Change-Id: Ic6fb92f70a0451db04ddf40344239a69312faf8f Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Prevent CoW detaches from happeningErik Verbruggen2019-04-152-13/+16
| | | | | | | | | | | | | | | Change-Id: Ia42c0d732e0f6ccfa2c70b86edccd9eb471aac7c Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Fix string replacement with invalid capturesUlf Hermann2019-04-151-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we have a theoretically valid capture reference that just didn't capture anything in this match, we don't want to treat it as literal. Only capture references that clearly are outside the range of things we can possibly capture with this expression should be treated as literal strings. Change-Id: Iab0bf329d11a6b9e172aa662f11751d86cfc26a6 Fixes: QTBUG-75121 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13v5.13.0-beta3Qt Forward Merge Bot2019-04-154-23/+56
| |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/3rdparty/masm/assembler/LinkBuffer.h src/qmltest/doc/src/qtquicktest-index.qdoc tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp Change-Id: I7d83ad95cf489dda794dd7a0a33bad3ef3b05609
| | * Only create the imports array if importCount is greater than 0Andy Shaw2019-04-141-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since it is possible that CompilationUnit::instantiate() might be called more than once when the importCount is 0 then it should only create the imports array when it is greater than 0. This prevents a memory leak due to the recreation of this array each time it is called even though there is no imports to assign. Change-Id: I5d84b01de10bff2ca25248251e8337839e434bd5 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Don't create value types for QImage and QPixmapUlf Hermann2019-04-122-11/+22
| | | | | | | | | | | | | | | | | | | | | | | | Those are "scarce" resources which need to be kept as QVariant. Fixes: QTBUG-74751 Change-Id: I28381e2a754ed4bbf4e409dc275f6288b64416cc Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Detect and reject cyclic aliasesUlf Hermann2019-04-091-10/+30
| | | | | | | | | | | | | | | | | | | | | | | | Previously those would result in infinite recursion. Fixes: QTBUG-74867 Change-Id: I6c0043b43e72fe7bc3a2a139ca600af2d5bca5ad Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | JIT: Avoid QString::sprintf()Ulf Hermann2019-04-172-3/+3
| | | | | | | | | | | | | | | | | | | | | It's deprecated Change-Id: Id901056e3a4ca378fb03486cd941e7e7222ffbc4 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Increment the private API versionUlf Hermann2019-04-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | The removal of QQmlV4Handle causes incompatible changes in private API that other modules use. Change-Id: I4f983e83a570c195c190f6d8c968f59f6adce21b Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Don't use UINT_MAX as invalid array index in PropertyKeyUlf Hermann2019-04-167-70/+75
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Technically UINT_MAX is actually a valid array index, although that is an academic problem right now. However, we do have a method isArrayIndex() and should just use that to determine if a PropertyKey is an array index. Fixes: QTBUG-73893 Change-Id: I302e7894331ed2ab4717f7d8d6cc7d8974dabb4e Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
* | | Remove QQmlV4HandleUlf Hermann2019-04-1020-92/+43
| | | | | | | | | | | | | | | | | | | | | | | | This is just an alias for QV4::ReturnedValue. We can as well use the latter. Change-Id: Ibd2c038a3ca726b39a8f0f05e02922adb9fccbdb Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Fix false unused parameter warningsRichard Weickelt2019-04-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When building Qt on Ubuntu 16.04 with gcc 5.4, build fails due to a warning about unused parameters. Warnings are treated as errors by default. This is most likely a bug in g++ and has probably been fixed in later versions. For instance, no warning is emitted for the synthesized operator= few lines further down. Above setup will be officially supported by Qt 5.14 and therefore, I suggest to work around this issue by omitting the explicit parameter names. Change-Id: Ifb22e39b7f5fa5101b188eec715d8620d4589941 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev" into ↵Ulf Hermann2019-04-108-13/+23
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-108-13/+23
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/qml/qml/qqmlmetatype.cpp src/qml/types/qqmlmodelsmodule.cpp Change-Id: Idc63689ba98d83a455283674f4b5cf3014473605
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13v5.13.0-beta2Qt Forward Merge Bot2019-04-093-1/+4
| | |\| | | | | | | | | | | | | Change-Id: I68211a7d4568a1c31c6a124fe6777709c53736a5
| | | * Don't use delegate model types on -no-feature-delegate-modelUlf Hermann2019-04-081-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-74884 Change-Id: I7a675f6ef41937cef0f8e67960486c5b022d735c Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * Avoid INT_MIN % -1 and INT_MIN / -1Ulf Hermann2019-04-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Those throw arithmetic exceptions as the result doesn't fit into an integer. Fixes: QTBUG-75030 Change-Id: Ibd978848f42cf1c9da1e4af2dc9d7da123ef8f5a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | | * Fix clang-cl compiler warningsKai Koehne2019-04-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | clang-cl.exe 8.0.0 warns: qv4internalclass_p.h(460,19): warning: unqualified friend declaration referring to type outside of the nearest enclosing namespace is a Microsoft extension; add a nested name specifier [-Wmicrosoft-unqualified-friend] The warning is most likely bogus (otherwise the code wouldn't compile on other platforms. But it's arguably not a bad idea to just qualify the friend declaration. Change-Id: Ia34119661c29cd8619adec70e9999cab2605ff32 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * | Remove second evaluation of property nameRainer Keller2019-04-081-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The name was evaluated already at the beginning of the function. Change-Id: I0bf6149c9bce83a543b1946330ec12f318620a71 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-024-11/+18
| | |\| | | | | | | | | | | | | Change-Id: I1dd04210f10895c509b5c637fc5e2dcf66e3bb91
| | | * Doc: Add missing quote in example codePaul Wicking2019-04-011-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-74851 Change-Id: Ib4c4b7fd3a01a360ae923f718e7ce74b3ae7f3eb Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
| | | * Doc: Use the \nullptr macro instead of 0Venugopal Shivashankar2019-03-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This enables overriding the macro so that it translates to 'None' in the Qt for Python context. Change-Id: Ied1ddcb0f9e6e2299d9042e4cc4c2bb6d11a491b Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | | * Avoid redundant slashes when creating qmldir URLsUlf Hermann2019-03-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the path starts with ":" and we assume it's an absolute qrc path, the only thing we need to do to make it a URL is prepend "qrc". Fixes: QTBUG-74677 Change-Id: Iee0239296b6f48ce909db02ae16e24dfc745b637 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
| | | * Allow enums in QQmlType to be set up in two separate passesUlf Hermann2019-03-281-8/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The baseMetaObject and the property cache can become available at different points in time. If we have initialized the enums before either of them is available we want to add the additional enums when the other one appears. Fixes: QTBUG-74677 Change-Id: I57276681a50b6c04181c6a29e736f2dc20632a0c Reviewed-by: Lars Knoll <lars.knoll@qt.io>