Index: src/interpreter/bytecode-generator.cc |
diff --git a/src/interpreter/bytecode-generator.cc b/src/interpreter/bytecode-generator.cc |
index 06eb53e92a499233fd83a0a73502eceeebf72b28..58f6e7288dc9c71e5c37863e4c643c0dbbfafaa0 100644 |
--- a/src/interpreter/bytecode-generator.cc |
+++ b/src/interpreter/bytecode-generator.cc |
@@ -1052,13 +1052,14 @@ void BytecodeGenerator::VisitIterationBody(IterationStatement* stmt, |
void BytecodeGenerator::VisitDoWhileStatement(DoWhileStatement* stmt) { |
LoopBuilder loop_builder(builder()); |
- VisitIterationHeader(stmt, &loop_builder); |
if (stmt->cond()->ToBooleanIsFalse()) { |
VisitIterationBody(stmt, &loop_builder); |
} else if (stmt->cond()->ToBooleanIsTrue()) { |
+ VisitIterationHeader(stmt, &loop_builder); |
VisitIterationBody(stmt, &loop_builder); |
loop_builder.JumpToHeader(); |
} else { |
+ VisitIterationHeader(stmt, &loop_builder); |
VisitIterationBody(stmt, &loop_builder); |
builder()->SetExpressionAsStatementPosition(stmt->cond()); |
VisitForAccumulatorValue(stmt->cond()); |