Chromium Code Reviews| Index: src/compiler/ast-graph-builder.cc |
| diff --git a/src/compiler/ast-graph-builder.cc b/src/compiler/ast-graph-builder.cc |
| index 0128e4622d462936c22cc451967d1002539cc2d2..ab9b5b5876f5dba5d292bb369ece95bd325a5cf4 100644 |
| --- a/src/compiler/ast-graph-builder.cc |
| +++ b/src/compiler/ast-graph-builder.cc |
| @@ -1920,7 +1920,6 @@ void AstGraphBuilder::VisitArrayLiteral(ArrayLiteral* expr) { |
| // The array and the literal index are both expected on the operand stack |
|
Michael Starzinger
2015/11/24 12:29:23
nit: Comment outdated, please adapt.
Benedikt Meurer
2015/11/24 12:30:43
Done.
|
| // during computation of the element values. |
| environment()->Push(literal); |
| - environment()->Push(literal_index); |
| // Create nodes to evaluate all the non-constant subexpressions and to store |
| // them into the newly cloned array. |
| @@ -1936,7 +1935,7 @@ void AstGraphBuilder::VisitArrayLiteral(ArrayLiteral* expr) { |
| VectorSlotPair pair = CreateVectorSlotPair(expr->LiteralFeedbackSlot()); |
| Node* value = environment()->Pop(); |
| Node* index = jsgraph()->Constant(array_index); |
| - Node* literal = environment()->Peek(1); |
| + Node* literal = environment()->Top(); |
| Node* store = BuildKeyedStore(literal, index, value, pair); |
| states.AddToNode(store, expr->GetIdForElement(array_index), |
| OutputFrameStateCombine::Ignore()); |
| @@ -1948,7 +1947,6 @@ void AstGraphBuilder::VisitArrayLiteral(ArrayLiteral* expr) { |
| // above. The second part is the part after the first spread expression |
| // (inclusive) and these elements gets appended to the array. Note that the |
| // number elements an iterable produces is unknown ahead of time. |
| - environment()->Pop(); // Array literal index. |
| for (; array_index < expr->values()->length(); array_index++) { |
| Expression* subexpr = expr->values()->at(array_index); |
| Node* result; |