| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This avoids the bool invert in the instruction
stream, and some additional code in the VME.
Change-Id: I0ea675a2e3d07c1b8c5234b888d8d9683bcee330
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: Ie01ef2be8beb890b1ca56bbdc990ccea87c1d91e
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Keep it in debug builds to ease debugging.
Change-Id: I334872d3c0ef30b5f09fb5febfc2129a3b450bca
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
These give a measurable speedup as the critical code
paths are now inline.
Change-Id: I3cee8a432fbe96d66ba1e6bd277a38e624a50c14
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This gives as performant but simpler code, as the first line
in toInt() checks if the value is integercompatible.
Change-Id: I15d0ade231719116ca1c6c03a86106b7f5aaa9aa
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
These parameters are not used outside the function itself
anymore, so we can safely remove them.
Change-Id: I1694481c05a9927fc78a59ffb7fec43a88e85ac8
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This simplifies and speeds up loading of constants
Change-Id: I05b4f7a34abd4ed6416fa800a31debbb28b37104
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Move to a class hierarchy that mirrors the main classes. This will
allow moving functionality over into the Ref classes, as the current
Managed classes become mainly something that holds the data. This
is required to make objects movable by the GC.
Change-Id: I4ca88ab0e5d8c88c8dc56d51937990500a33e0d9
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
First step of removing the templates here and turning this
into a class hierarchy. This is required, so we can move all
member methods into the Ref classes and make objects movable
during GC.
Change-Id: Ie14af07fd3e72a7d84a528d0042189ff12ba21bb
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The two classes belong logically together (as the Managed base
type and a generic pointer to a Managed object).
Change-Id: I65691669a7169a4514cadf7ab3e744c090851c6b
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Better don't leak passwords via accessibility
Change-Id: Ibdb0f63101dbd71f51de6f1b8ddaceb359f01e30
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Because qtdeclarative was merged back from stable and qtbase is
still lagging behind, they have become unsynchronized, causing
crashes when trying to get the device name from the platform
plugin and failing. To work around this until the merge goes
through, I've added a simple guard.
Task-number: QTBUG-36658
Change-Id: Ibc399ed325a1fbdeccad85ed8d4841edb7b2ba5d
Reviewed-by: BogDan Vatra <bogdan@kde.org>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The earlier pattern of
Property p;
p.setSetter(new (mm) setterFunction);
p.setGetter(new (mm) getterFunction);
carries the risk of the second allocation garbage collecting the first one.
Consequently we need to put these values onto the JS stack, using a simple
ScopedProperty wrapper.
Change-Id: Ib29ea3b1eab95595dd6dfbb86fea282d23e3d899
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
qmlContext(this) is expected in re-implementations of classBegin(), so just
like the VME we have to be careful that we call it after setting the context
on the ddata.
Change-Id: I38ad8d1a4e4093368f62f9d57718de3b8cd0cfd2
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
We must take the imported scripts from the creation context. Fixes various
errors in Qt Quick Controls.
Change-Id: I336d8ffa0537cefd4eeac15f98bbf1b0a5c784af
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Without this new engines can be added to the QV4DebugService while
breakpoints are set from the debugger thread. In rare cases this leads
to a situation where the DebuggerAgent::addDebugger() doesn't see the
new breakpoint and DebuggerAgent::addBreakPoint() doesn't see the new
debugger. Thus the breakpoint will never be set.
This effect is easily reproducible by repeatedly (about 100 times)
running the setBreakpointInScriptOnTimerCallback autotest.
Change-Id: I5da27478bf579ab24f81aebabbdd321f38fae3f4
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Let the debug server handle adding and removing of engines through
defined interfaces to prepare for multi-engine profiling and debugging.
Change-Id: I7b277e54bdcce1d3e95e723f041a7db6b08b29fc
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
They deserve having their own set of files, and it helps
reduce dependencies.
Change-Id: Ifd4394f88ef51cbccc61bf92dd20636f570141d9
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Move commonly used variables in the ExecutionEngine
to the beginning of the struct to increase cache locality.
Keep the engine pointer in a register in the interpreter to
save one memory load per instruction.
Change-Id: If2540c66b62685701511f410aff495c0a20ca694
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Fortunately we don't use this constructor anymore. This also
allows us to fix the assert in qv4managed. Now we finally
enforce that every managed object must have an internal class
and a vtable.
Change-Id: Idf9081c20633b44b79970fec4cc4d1ec5e6a6f7c
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
This avoid having to check for the debugger at every instruction
we execute. Instead we only add debug instructions at the beginning
of every line and every basic block when we have a debugger.
This still allows interrupting the JS execution at any time (as we
can't loop inside a basic block), and single stepping through lines.
But it has no overhead when the debugger is not running and a lot
less when it is running.
Change-Id: Ib17170b42944b608fc6caa1891082205dd2b2763
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I614cc1428439801ed20cdee099cf8260ff930618
Reviewed-by: Liang Qi <liang.qi@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
You can have a binding like this:
property point blah: Qt.point(someX, someY);
and later you can have bindings on
blah.x: { someExpression }
In that case we need to clear the binding on blah.
Change-Id: I27bfa6ab0f104bf989803c5910e6094767429c03
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
qqmlecmascript's alias binding tests expect bindings on non-aliases to be bound
before bindings on aliases, as the latter may override parts of the former.
Change-Id: I23d25c2b7a449f0ed4672ef6865c4a7ef0ed0129
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When installing bindings on aliases, make sure to follow the alias.
Change-Id: I860a5bf6b5aba838727385f26e50e3d1bf0c8ea8
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: Iaf96dabb1b3de81aae75953fd261dfc3b562169c
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
It's allowed to call destroy() on them, so allow for destruction
unless the constructor set ownership upfront.
Change-Id: I3887c5ab1bb6de7de3b0c7b14f4791d4ed1e0979
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Since commit 3d958cec8d53094a1bbab895377e451b07716e1f (loong time ago!)
property bindings are stored in a linked list and newly encounted bindings
at parse time are prepended to the list, causing the binding processing to
happen in reverse order.
There are however exception to the rule. For example list bindings are processed
in declaration order and assignments to the default property are sorted by
location in the file.
In addition various tests rely on value properties being installed first, then
followed by signal handlers and group/attached properties.
Change-Id: I3bcae29faec5b2420fbba362cd81b8ba960ed19f
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Ensure that the empty string always has index 0, that simplifies the code in a
few places and makes it easier to check for the empty string in other places
where there's no access to the string pool itself.
Change-Id: Icd204aec478e8350ef3fee75d89bda1f88cffe26
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
In some places we allocate custom array objects and in the constructor we call
setArrayType, which will allocate the array's data through the GC. In all of
these cases we need to make sure that the array object itself is protected from
garbage collection, because while in the constructor it may not be yet in the
scope the callee has usually set up.
Change-Id: I96b7af4ae00fd809067e12bacd6563984c5e9240
Reviewed-by: Erik Verbruggen <erik.verbruggen@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | | |
Change-Id: I67d961f23941ba5cfa16fd679b609cd0fc3071c7
Reviewed-by: Michael Brasser <michael.brasser@live.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Profiling shows Qt Creator spends 2% of its load time normalizing
Change-Id: I58132e11ab5fc942b04925c3bcc919165784a5d1
Reviewed-by: Alan Alpert <aalpert@blackberry.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Task-number: QTBUG-34736
Change-Id: Ic0ab7317c76417e6556bc0b26cad50416ba06e54
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The property cache among other things caches the parameter types and names
of signals (instead of retrieving them from the meta-object each time). When
this cache is created through createArgumentsObject(), the parameter names have
to be provided, but the signature didn't enforce that because of the parameter
names having a default value of an empty list. All call sites however provided
the correct list, except for one in QQmlPropertyCache::methodParameterTypes.
Consequently tst_qqmlecmascript::threadSignal() would fail occasionally because
the first time this cache was "created" was when the "done" signal was emitted,
which caused QQmlBoundSignalExpression::evaluate to call methodParameterTypes. If
the signal data had not been cached so far, a new cache with an empty parameter
name list was created.
Later (in the second half of the test) a new signal handler was compiled and
the property cache reported that the signal took no parameters.
Change-Id: I19230d0fb1ddd54992f3d6251f82c489626662e7
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I3b99f3fc762df7ac820b26597bf809a80849b5ce
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
After recordError makes sure to return false to indicate the error condition
to the caller.
Change-Id: I7edcda9ea4c6898f1607824085b150dbe295aeb2
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
themselves
They should share the imports from the importing context, which means
context->importedScripts needs to be initialized before calling
scriptValueForContext, because it accesses it.
Change-Id: Ifed22555028e03d597954ba1a18e546bfb901c58
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
signals
Change-Id: Ie2dc8689786a61fe5f38a0f91ff86f011e965b2d
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Always install the property cache on the ddata, not only for types with
a VME meta object, as the cache has the correct revision cache.
Change-Id: I82352df867c1045b37152013eb924aafde2ee874
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
signal handlers
Functions need to be setup first, like in the VME.
Change-Id: I4d1cffa04cb2b3ba7027c3720d55133253a1bad7
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: Icb8c2dfc633a6c322d4448ce18e3c01e0311b0f4
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
interceptors
Change-Id: I3dd608bfceb04323f92503596b87bbcb4bf582fc
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Also adjust the error message for the other compiler when trying to assign
lists to script strings.
Change-Id: I50f833c340f3634a59c5b36f30aeafc53003e65e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: Ic7f1938dd048db6c6975d78ad4f69d3c646cece5
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Separate binding errors from property declaration errors - they were
accidentally mixed up.
Change-Id: Id2d5134dc98ee3e1d7ce0c3d356f165e144e0d82
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When creating the initial object tree from the AST, encapsulate the
declarations and bindings in the QmlObject class, in order to centralize the
redirection via declarationsOverride as well as the error handling. This also
replaces the hashes to detect duplicate properties/signals from being QString
based to simply use the existing string indices from the compilation unit.
Change-Id: Ia6ceae56977a98b5c5a7a738bf983a731e608d46
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
When an ID is specified as string literal, which is empty, don't try to
take the literal quotes as ID. Instead it's empty and so an error needs
to be thrown.
Change-Id: I9b42295a33dceb3cc9e57456908c65bbc12eb296
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
... by taking some code from the old compiler. This speeds up some bindings
and maintains compatibility.
Change-Id: If80b1e28214cb655f70fff01a8c885edcb2d3030
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I7549930a1152c257b3da6951afefef5d8b783f32
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|
| | |
| | |
| | |
| | |
| | | |
Change-Id: I22c3e3f8e9a06928a23700b657a656a0db37d48d
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
|