aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4codegen.cpp
diff options
context:
space:
mode:
authorLars Knoll <lars.knoll@qt.io>2017-08-29 13:12:17 +0200
committerLars Knoll <lars.knoll@qt.io>2017-08-30 08:09:13 +0000
commit260a24800dcdf3fa6ad4a8d0abaa0c8b23aae511 (patch)
tree7382fd5a6f00ffd05ae45a86e803d7454d070ad3 /src/qml/compiler/qv4codegen.cpp
parente931b123e90ca0162e112148de5cd35f149e4841 (diff)
Remove the codeRefs in the Moth::CompilationUnit
There's no point in allocating that vector of byte arrays, if we can directly embed those int the CompiledData and reference it from there. Change-Id: I8fc92b1efaca5a9646f40fc84a2ac4191c8f3444 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Diffstat (limited to 'src/qml/compiler/qv4codegen.cpp')
-rw-r--r--src/qml/compiler/qv4codegen.cpp5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/qml/compiler/qv4codegen.cpp b/src/qml/compiler/qv4codegen.cpp
index 7643212ea1..ea3f194852 100644
--- a/src/qml/compiler/qv4codegen.cpp
+++ b/src/qml/compiler/qv4codegen.cpp
@@ -2731,11 +2731,6 @@ QList<QQmlJS::DiagnosticMessage> Codegen::errors() const
QQmlRefPointer<CompiledData::CompilationUnit> Codegen::generateCompilationUnit(bool generateUnitData)
{
Moth::CompilationUnit *compilationUnit = new Moth::CompilationUnit;
- compilationUnit->codeRefs.resize(_module->functions.size());
- int i = 0;
- for (Context *irFunction : qAsConst(_module->functions))
- compilationUnit->codeRefs[i++] = irFunction->code;
-
if (generateUnitData)
compilationUnit->data = jsUnitGenerator->generateUnit();