| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
We need to preserve them as they notify us about protoId related
changes. In order to avoid wasting heap space in case many properties
are added and removed from the same object, we put a mechanism in place
to rebuild the InternalClass hierarchy if many redundant transitions are
detected.
Amends commit 69d76d59cec0dcff4c52eef24e779fbef14beeca.
Fixes: QTBUG-91687
Task-number: QTBUG-58559
Change-Id: I3238931b5919ed2b98059e0b7f928334284ce7bf
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
(cherry picked from commit 0b9fa18dfefc06f542bd0c98b7e41fa14aa0c2cf)
|
|
|
|
|
|
|
|
|
|
|
| |
If an inner function contains a yield expression, we need to reject the
program even if that function is inside of a generator function.
Fixes: QTBUG-98356
Change-Id: I2e820a1ca5f0da4080e313fd9809aa8bfdc1b681
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit dde1d86baabac1eddd84a11b7d2ed49e26c511bd)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Top level functions, that is, those directly defined in a QML component
as opposed to those defined inside another function or class, are not
visited directly by the ScanFunction visitor. Instead, they are manually
considered in generateJSCodeForFunctionsAndBindings, and the visitor is
then run on their body.
This worked mostly fine, with one notable exception: In case there is a
function expression used as the default value of a function parameter,
that function would have never been visited. This would lead to
subsequent asserts/crashes in the codegen, as the function was not
properly set up.
We fix this by manually visiting the function's formals in addition to
the body.
Fixes: QTBUG-98032
Change-Id: I5cb4caae39ab45f01a0dfa1555099d7d4b796a19
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit be194d965d530e57ed5851781c6805e691c6ae98)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The member was marked as a Pointer for the gc; however it was never
used, and thus also left uninitialized. This could cause memory
corruption or asserts during the gc's mark phase.
Fixes: QTBUG-95417
Change-Id: Ide826c0284b6060de8689e6f0dc753011108dba9
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Maximilian Goldstein <max.goldstein@qt.io>
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
(cherry picked from commit d36b480a956e2437888925aa8a1f5e3cb6c06ebd)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Previously HeapObject::GeneratorObject utilized a ValueArray member to store stack information.
As we rely on all HeapObject members to have a constant size in order for QV4Table::inlinePropertyOffset
to remain accurate, this lead to a memory conflict when a user defined his own property on the Generator.
Please do not use ValueArray for any types that are user accessible or that you intend to add properties to.
Now the stack information is stored into ArrayObjects instead which circumvents the issue.
Fixes: QTBUG-91491
Change-Id: Id6f638bf36a3ae3c9320ac99e67214c48dc81226
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Andrei Golubev <andrei.golubev@qt.io>
(cherry picked from commit 7ea690c61dabd2485e80e7fae9aed392ba02c846)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
|
|
|
|
|
|
|
|
|
|
|
| |
If the target of a proxy was extensible, we did not set the
iteratorTarget to its correct value, and thus the ForInIteratorObject
would not be usable.
Fixes: QTBUG-86323
Change-Id: Id1924ac4087bab38c006b8eba92b619b79d36b7a
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit dd740d6b3469448dc1fd31c1742781e923e9f274)
|
|
|
|
|
|
|
|
|
|
|
|
| |
Property pointer p needs to be checked for nullptr value in
QV4::ProxyObject::virtualGetOwnProperty(). This can happen when calling
hasOwnProperty() or propertyIsEnumerable().
Fixes: QTBUG-88786
Change-Id: I43da58fed4d8656f9187213f7317f17398739e34
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit 9b321a34490cd17c0eb043b69bd7c9d8d8f513d5)
Reviewed-by: Richard Weickelt <richard@weickelt.de>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When it is looking for a matching method based on the argument types,
then if a QVariant can be converted to that type then it should give a
better score for that method. This is so that it can see it as being
more viable a choice when calling the method instead of potentially
not being able to find a matching one.
Change-Id: Ief7e11feacd1d0b0959330af2576c2d01affbc54
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
(cherry picked from commit a056cb9595ea4a41c93f4c912719f9523b943d3b)
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|
|
|
|
|
|
|
| |
The Qt version was added in 5.14 "for use as eventual replacement for
QString::SplitBehavior." Move another step cloaser to that goal.
Change-Id: I3214ad6ccaca9dfd4a026589cabeb40cbf4a6298
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
src/qml/types/qqmlbind.cpp
src/quick/items/qquicklistview.cpp
tests/auto/qml/qqmllanguage/tst_qqmllanguage.cpp
Change-Id: Id6805c13256ad13d5651011e5dd09bba0ec02987
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
We started to convert containers to QJSValues, so that we could use them
as JavaScript arrays. Unfortunately, this would then lead to a type missmatch
when those same values where to be stored in a property of the container
type. This commit fixes this by converting them back to the original
type.
Fixes: QTBUG-80916
Change-Id: I30a3b03e17c34b171d4a6881dfd7801c13e94d80
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The sameValue(Zero) algorithm were implemented according to the
JavaScript specification; however QML has the concept of value types.
For those we need to check equality with the intrinsic isEqualTo method.
This aligns sameValue(Zero) with strict equality in its treatment of
value types.
This fixes Array.includes for value types
Fixes: QTBUG-81825
Change-Id: Idd3e09cbed94bca6ea44f5683610b87d184e432c
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\|
| |
| |
| |
| |
| |
| |
| |
| | |
Conflicts:
src/particles/qquickitemparticle.cpp
src/qmlmodels/qqmladaptormodel.cpp
tests/auto/particles/qquickitemparticle/tst_qquickitemparticle.cpp
Change-Id: Ibd8fbb91da6893a09f4ffe61ad0b95d8149bbc87
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
MemoryManager::collectFromJSStack did push to the mark stack without
checking if there is actually still space available. To fix this, we now
drain the stack once we hit the limit.
The test case is a slightly modified version compared to the reported
one, removing one loop. This was required as our regular expression does
not throw an exception when there are too many capture groups. However,
to trigger the bug, looping was not actually necessary.
Change-Id: I4d00865f25a989c380f4f5b221f4068c80b71d2b
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\|
| |
| |
| |
| |
| |
| | |
Conflicts:
src/qml/common/qv4compileddata_p.h
Change-Id: I1150c8cd0161f0e22137d383013751394ae64e18
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Previously, the code generator would truncate the stack slots when
writing the compiled function, as that one only had a 16bit field for
them.
Also, add a debug-mode check for stack overflows to the interpreter.
Unfortunately, as it triggers a stack overflow, the test will not
reliably fail without this change.
Fixes: QTBUG-80511
Change-Id: I3019bb2de657ae4c3e1040db798a83533f854bff
Reviewed-by: Paolo Angelelli <paolo.angelelli@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|\|
| |
| |
| | |
Change-Id: I1359574c7d89aaf3328958e2f667ba1e599ff7f1
|
| |\
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/plugins/scenegraph/openvg/qsgopenvgcontext.cpp
tests/auto/quick/qquickpathview/tst_qquickpathview.cpp
Change-Id: I117c8d62b21800329d1035021d312d9924f83a1b
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The ES Date spec goes into minute detail about doing various
algorithms in the dumbest possible way (like InLeapYear() calling
DaysInYear(), rather than the other way round) but, in MakeDay(),
leaves the implementation to solve the problem of finding the start of
the first day of a specified month in a given year. So exercise the
freedom we have in that to be a little more robust; and actually check
we have met the conditions the spec requires, returning NaN (as
specified) if not.
Added tests for some denormal dates and date-times and for a date
mentioned in QTBUG-78996.
Task-number: QTBUG-78996
Change-Id: I8d9a841dd1f1d9995273a3de8f6f9130207c7c2b
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/imports/qtquick2/plugins.qmltypes
src/quick/items/qquickitemsmodule.cpp
Change-Id: I841c65c9c131354788b4f3fcfe3d7ed27be316d5
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The result from component.create() has to be deleted somewhere.
Change-Id: I23135cb639fc316641e399decc740d9f5d445a84
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |\|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/jit/qv4baselinejit.cpp
src/qml/jsruntime/qv4vme_moth.cpp
tests/auto/qml/qqmlecmascript/tst_qqmlecmascript.cpp
Change-Id: Iec7cd27ddad0281bd3b7833fb6b252f66a6ae5d6
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Otherwise QString::number() will apparently extend "negative" values to 64bits
even if the actual type is only 32bits long.
Change-Id: Ibdecff2fe707616d2254b7e34e08247f0ff52489
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
Reviewed-by: Assam Boudjelthia <assam.boudjelthia@qt.io>
Reviewed-by: Liang Qi <liang.qi@qt.io>
|
|\| |
| | |
| | |
| | | |
Change-Id: Icc46cb06ac1dbe7097d11bc0db5813eb39fbf758
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Most of the rules already had Semicolon at the end, however it was
missing for UiScriptStatement, list properties and UiObjectInitializer.
This change fixes the regression from 5.11.3 to 5.12.0, and keeps the
behavior consistent.
Fixes: QTBUG-77954
Change-Id: I45ef35fab399e3f971444b96d4a9ec6a99e29e09
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|/ /
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
First, let the lexer create a T_FUNCTION_STAR token for "function *",
which makes the job of the parser significantly easier.
Then, by using GeneratorDeclaration instead of GeneratorExpression, we can
avoid the conflicts between UiObjectMember and PrimaryExpression
Change-Id: Ib08918e3977ed1a80cdea0948da80bf37886f7de
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Extends grammar to support generator functions in QML components and
adjusts codegen accordingly
The corresponding test case must be blacklisted in tst_qmlmin, as qmlmin
cannot handle yield statements
Fixes: QTBUG-77096
Change-Id: I47d45dd56289cdf073b41932a585259d3052de04
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Some silly ignoreMessage failures on 32 bit systems..
QString::number((quint32)0xaabbccdd, 16) returns "0xaabbccdd"
while
QString::number((qint32)0xaabbccdd, 16) returns "0xffffffffaabbccdd"
We therefore change to use quintptr (which will follow the quint32
codepath).
Change-Id: I40530d8da83ee43862541f0e87684dc11ed07a53
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
| |
| |
| |
| |
| |
| |
| | |
No one can read this mess.
Change-Id: Icec4f2afc466435c1ae5e4e80fa2c1b5baf7d087
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\|
| |
| |
| |
| |
| |
| | |
Conflicts:
.qmake.conf
Change-Id: I20ad6f8a260f387a3b73566a32c35a5772b401a5
|
| |\
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
.qmake.conf
Change-Id: Icd05d016de5b4cf9af5234cb47b5c3fd0f6a053e
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Commit 7cb6dce1f3e140ea68d6b05281950f212fc99d38 introduced an
optimization to remove bindings that after their initial evaluation had
no dependencies or errors (such as when accessing properties not set
yet). However when accessing a context property in a silent way -- using
typeof -- then no error state is set and the binding is removed. Any
later change of the context property results therefore in no binding
re-evaluation. This patch skips the optimization on bindings that are
associated with a context that has unresolved names. This fixes the
concrete bug at the expense of disabling further optimizations in the
context if other bindings access unresolved context properties. However
since context properties are discouraged anyway, this may be an
acceptable price to pay.
Change-Id: I95e120a4f71e8ebe0ec1fc44e8703c75f920dd28
Fixes: QTBUG-76796
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/imports/imports.pro
src/qml/qml/qqmlmetatype.cpp
Change-Id: I308436caf55402cb2246cb591c6ac8f83e1febf8
|
| |\|
| | |
| | |
| | | |
Change-Id: I59343fe228ca6b823b61577e5a0907e7381899c2
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Just like resolving the lookup initially, we need to set the base also
when hitting the cached lookup code path. The base is then used as this
object.
Fixes: QTBUG-76656
Change-Id: I6f6be05bc9875ddccc6e112e91176a0fa24a8fa1
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/jsruntime/qv4value_p.h
src/qml/qml/qqmlmetatype.cpp
src/qml/qml/qqmltypewrapper.cpp
src/quick/items/qquicktableview.cpp
Change-Id: I684f8e01a711580512848bf1253f39b39fcbf4c7
|
| |\|
| | |
| | |
| | | |
Change-Id: I208cd36d2b7add94f36e4d86cf0c790a1e4a7e86
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
An unqualified name that points to a QML singleton will evaluate to a
QQmlTypeWrapper JS object. A member lookup in such an object is not
guaranteed to always produce the same property. The property cache check
may protect us from that, but we must still retrieve the QObject
singleton for every lookup.
Task-number: QTBUG-75896
Change-Id: Ibd9bac6e5c2047f838758811790b299ace636446
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I6b5cebb75ceeed6664a5d239ee8ce66b171f2667
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\| |
| | |
| | |
| | | |
Change-Id: I5d2c3da38df35922b2147c3c0bc55c6c3bae2fe5
|
| |\|
| | |
| | |
| | | |
Change-Id: Ic008bf9223a9ac293c925044355ff218f7ed7f78
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Nobody needs those and we run into integer overflows later on if we
accept them.
Fixes: QTBUG-74048
Change-Id: Ib8ccd05e4bd6f662c38fbe95bf1350f81982e1b8
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/qml/qqmlmetatype.cpp
Change-Id: Ieff61c076e46eb50a059c8b0210f7f4d7ce0cbcf
|
| |\|
| | |
| | |
| | | |
Change-Id: I9ef4be23bfe35aa48d4c65d4159e72c527943845
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: I613bf5dc685bb4235262b429d8f7318ea144fb9d
Fixes: QTBUG-75203
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/qml/qqmlmetatype.cpp
src/qml/types/qqmlmodelsmodule.cpp
Change-Id: Idc63689ba98d83a455283674f4b5cf3014473605
|
| |\|
| | |
| | |
| | | |
Change-Id: I68211a7d4568a1c31c6a124fe6777709c53736a5
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
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 warnings like:
sruntime/qv4serialize.cpp:378:45: warning: 'QVariant qVariantFromValue(const T&) [with T = QQmlListModelWorkerAgent::VariantRef]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
qml/qqmlvmemetaobject.cpp:597:61: warning: 'QVariant qVariantFromValue(const T&) [with T = QList<QObject*>]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
jsruntime/qv4engine.cpp:1319:66: warning: 'QVariant qVariantFromValue(const T&) [with T = QObject*]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
jsruntime/qv4engine.cpp:1350:60: warning: 'QVariant qVariantFromValue(const T&) [with T = QList<QObject*>]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickitem.cpp:8396:78: warning: 'QVariant qVariantFromValue(const T&) [with T = QObject*]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickitem.cpp:8693:80: warning: 'QVariant qVariantFromValue(const T&) [with T = QObject*]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickgenericshadereffect.cpp:126:69: warning: 'QVariant qVariantFromValue(const T&) [with T = QObject*]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickgenericshadereffect.cpp:127:55: warning: 'QVariant qVariantFromValue(const T&) [with T = QSize]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickopenglshadereffect.cpp:713:69: warning: 'QVariant qVariantFromValue(const T&) [with T = QObject*]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
items/qquickopenglshadereffect.cpp:714:55: warning: 'QVariant qVariantFromValue(const T&) [with T = QSize]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
qquickcustomparticle.cpp:416:89: warning: 'QVariant qVariantFromValue(const T&) [with T = double]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
qqmlenginedebugclient.cpp:403:47: warning: 'QVariant qVariantFromValue(const T&) [with T = QQmlEngineDebugObjectReference]' is deprecated: Use QVariant::fromValue() instead. [-Wdeprecated-declarations]
Task-number: QTBUG-74043
Change-Id: I14cb7d7c1fb8dc6321e32208a7de15f6bdb19065
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
|
|\| |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Conflicts:
src/qml/compiler/qv4compileddata_p.h
src/qml/jit/qv4baselinejit.cpp
src/qml/jit/qv4jithelpers.cpp
src/qml/jsruntime/qv4lookup.cpp
src/qml/jsruntime/qv4runtime.cpp
src/qml/jsruntime/qv4runtimeapi_p.h
src/qml/jsruntime/qv4vme_moth.cpp
src/qml/qml/qqmltypemodule_p.h
Change-Id: If28793e9e08418457a11fc2c5832f03cab2fcc76
|