summaryrefslogtreecommitdiff
path: root/src/qml/compiler/qv4compileddata.cpp
diff options
context:
space:
mode:
authorSimon Hausmann <simon.hausmann@qt.io>2018-07-23 09:42:16 +0200
committerSimon Hausmann <simon.hausmann@qt.io>2018-07-31 17:08:00 +0000
commit9337b1c339c34cd4fe10d236be2ee61ca76e17ba (patch)
tree4fa5482063e447dc7d9988069cdeafd255e8933b /src/qml/compiler/qv4compileddata.cpp
parent0a0e6e2ad2ed8224b5c1b6cd179677198e87288c (diff)
downloadqtdeclarative-9337b1c339c34cd4fe10d236be2ee61ca76e17ba.tar.gz
Clean up compilation unit string resolution
Replace use of CompiledData::Unit::stringAt with CompilationUnit::stringAt as central place, in preparation for allowing derived compilation units to retrieve strings from base units. Change-Id: Ifafe6c18a9fd8d1e2259a60c17200124869b4c2d Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Diffstat (limited to 'src/qml/compiler/qv4compileddata.cpp')
-rw-r--r--src/qml/compiler/qv4compileddata.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/qml/compiler/qv4compileddata.cpp b/src/qml/compiler/qv4compileddata.cpp
index d9e58bb6e8..84abd081cf 100644
--- a/src/qml/compiler/qv4compileddata.cpp
+++ b/src/qml/compiler/qv4compileddata.cpp
@@ -130,7 +130,7 @@ QV4::Function *CompilationUnit::linkToEngine(ExecutionEngine *engine)
// memset the strings to 0 in case a GC run happens while we're within the loop below
memset(runtimeStrings, 0, data->stringTableSize * sizeof(QV4::Heap::String*));
for (uint i = 0; i < data->stringTableSize; ++i)
- runtimeStrings[i] = engine->newString(data->stringAt(i));
+ runtimeStrings[i] = engine->newString(stringAt(i));
runtimeRegularExpressions = new QV4::Value[data->regexpTableSize];
// memset the regexps to 0 in case a GC run happens while we're within the loop below
@@ -146,7 +146,7 @@ QV4::Function *CompilationUnit::linkToEngine(ExecutionEngine *engine)
ignoreCase = true;
if (re->flags & CompiledData::RegExp::RegExp_Multiline)
multiline = true;
- runtimeRegularExpressions[i] = QV4::RegExp::create(engine, data->stringAt(re->stringIndex), ignoreCase, multiline, global);
+ runtimeRegularExpressions[i] = QV4::RegExp::create(engine, stringAt(re->stringIndex), ignoreCase, multiline, global);
}
if (data->lookupTableSize) {