diff options
author | Simon Hausmann <[email protected]> | 2013-11-17 18:07:06 +0100 |
---|---|---|
committer | The Qt Project <[email protected]> | 2013-11-28 15:12:06 +0100 |
commit | 4bf6969d8a1e17911a076ac470a38a464d7322a2 (patch) | |
tree | 5d2209c4d90cef64fac6f77bf3e86307de3f7f21 /src/qml/compiler/qv4ssa.cpp | |
parent | d72adccd2727d55a8f0adb87cfa9ef22db27ff9e (diff) |
Slightly accelerate access to value type properties
We can't do a fast property index based access on them, due to the inability to
read individual fields from the original object (i.e. the logic in
QQmlValueTypeWrapper). However what we can determine and propagate is the type
information of the individual properties, i.e. that the x and y properties of a
QPointF are always doubles.
Change-Id: Iee71ece2117294b7bc0b93deb0a77d7c51148b11
Reviewed-by: Lars Knoll <[email protected]>
Diffstat (limited to 'src/qml/compiler/qv4ssa.cpp')
-rw-r--r-- | src/qml/compiler/qv4ssa.cpp | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/src/qml/compiler/qv4ssa.cpp b/src/qml/compiler/qv4ssa.cpp index 5e2c7ba722..249dfab660 100644 --- a/src/qml/compiler/qv4ssa.cpp +++ b/src/qml/compiler/qv4ssa.cpp @@ -1906,12 +1906,8 @@ protected: } } - // Don't convert when writing to QObject properties. All sorts of extra behavior - // is defined when writing to them, for example resettable properties are reset - // when writing undefined to them, and an exception is thrown when they're missing - // a reset function. const Member *targetMember = s->target->asMember(); - const bool inhibitConversion = targetMember && targetMember->property; + const bool inhibitConversion = targetMember && targetMember->inhibitTypeConversionOnWrite; run(s->source, s->target->type, !inhibitConversion); } |