diff options
author | Lars Knoll <lars.knoll@qt.io> | 2018-01-03 14:06:28 +0100 |
---|---|---|
committer | Lars Knoll <lars.knoll@qt.io> | 2018-01-19 10:13:51 +0000 |
commit | 959ad9f998c340257a4027db4bed3a5639a8f48f (patch) | |
tree | ddfd60b00306c0dbeb216f8acb929da133da9440 /src/qml/jsruntime/qv4runtime.cpp | |
parent | 0e8546f6b8faf5fb14fc249d9f39f1c4266b2965 (diff) |
Split up String type into a regular and a ComplexString
Saves some memory for many cases, and will allow re-using the
String itself as an identifier
Change-Id: I462d63bc6f113dff1dce0de28ee4eea3949a4b95
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/jsruntime/qv4runtime.cpp')
-rw-r--r-- | src/qml/jsruntime/qv4runtime.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/jsruntime/qv4runtime.cpp b/src/qml/jsruntime/qv4runtime.cpp index 93d538127b..e7a104af66 100644 --- a/src/qml/jsruntime/qv4runtime.cpp +++ b/src/qml/jsruntime/qv4runtime.cpp @@ -532,7 +532,7 @@ QV4::ReturnedValue RuntimeHelpers::addHelper(ExecutionEngine *engine, const Valu if (!sright->d()->length()) return sleft->asReturnedValue(); MemoryManager *mm = engine->memoryManager; - return (mm->alloc<String>(sleft->d(), sright->d()))->asReturnedValue(); + return (mm->alloc<ComplexString>(sleft->d(), sright->d()))->asReturnedValue(); } double x = RuntimeHelpers::toNumber(pleft); double y = RuntimeHelpers::toNumber(pright); |