aboutsummaryrefslogtreecommitdiffstats
path: root/src/qml/compiler/qv4isel_moth.cpp
diff options
context:
space:
mode:
authorErik Verbruggen <erik.verbruggen@digia.com>2016-02-23 15:27:25 +0100
committerErik Verbruggen <erik.verbruggen@theqtcompany.com>2016-03-05 12:18:05 +0000
commit3cc5c3b845b6c26d2e6c35de4672bd55b7e192b0 (patch)
tree0c1d05147360b45ca6b779f2f97e403644a5916d /src/qml/compiler/qv4isel_moth.cpp
parent06d82fdbce5f647ac2651cc28eede456c681953c (diff)
V4: Replace foreach with range based for loops for statements.
Function::basicBlocks() returns a const reference to a QVector, so it can safely be iterated over without qAsConst. Change-Id: Ie9a17edfff7c1fbdc3601121935aef4b41338a35 Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Diffstat (limited to 'src/qml/compiler/qv4isel_moth.cpp')
-rw-r--r--src/qml/compiler/qv4isel_moth.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/qml/compiler/qv4isel_moth.cpp b/src/qml/compiler/qv4isel_moth.cpp
index dcedc54b6e..7d6d7e65bc 100644
--- a/src/qml/compiler/qv4isel_moth.cpp
+++ b/src/qml/compiler/qv4isel_moth.cpp
@@ -385,7 +385,7 @@ void InstructionSelection::run(int functionIndex)
addInstruction(push);
currentLine = 0;
- QVector<IR::BasicBlock *> basicBlocks = _function->basicBlocks();
+ const QVector<IR::BasicBlock *> &basicBlocks = _function->basicBlocks();
for (int i = 0, ei = basicBlocks.size(); i != ei; ++i) {
blockNeedsDebugInstruction = irModule->debugMode;
_block = basicBlocks[i];