Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(724)

Unified Diff: src/parser.cc

Issue 15740007: Add for-of Crankshaft support Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase onto master; fix AstTyper for ForOfStatement Created 7 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/ia32/full-codegen-ia32.cc ('k') | src/typing.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/parser.cc
diff --git a/src/parser.cc b/src/parser.cc
index fa24bf703bc6f62a039580db9731c0a6ae131c85..aae44e48887a20343dcdcaa16f0d31cccae2aef7 100644
--- a/src/parser.cc
+++ b/src/parser.cc
@@ -2674,7 +2674,7 @@ void Parser::InitializeForEachStatement(ForEachStatement* stmt,
ZoneList<Expression*>* next_arguments =
new(zone()) ZoneList<Expression*>(0, zone());
Expression* next_call = factory()->NewCall(
- next_property, next_arguments, RelocInfo::kNoPosition);
+ next_property, next_arguments, top_scope_->start_position());
Expression* result_proxy = factory()->NewVariableProxy(result);
next_result = factory()->NewAssignment(
Token::ASSIGN, result_proxy, next_call, RelocInfo::kNoPosition);
@@ -2686,7 +2686,7 @@ void Parser::InitializeForEachStatement(ForEachStatement* stmt,
factory()->NewLiteral(heap_factory->done_string());
Expression* result_proxy = factory()->NewVariableProxy(result);
result_done = factory()->NewProperty(
- result_proxy, done_literal, RelocInfo::kNoPosition);
+ result_proxy, done_literal, top_scope_->start_position());
}
// each = result.value
@@ -2695,7 +2695,7 @@ void Parser::InitializeForEachStatement(ForEachStatement* stmt,
factory()->NewLiteral(heap_factory->value_string());
Expression* result_proxy = factory()->NewVariableProxy(result);
Expression* result_value = factory()->NewProperty(
- result_proxy, value_literal, RelocInfo::kNoPosition);
+ result_proxy, value_literal, top_scope_->start_position());
assign_each = factory()->NewAssignment(
Token::ASSIGN, each, result_value, RelocInfo::kNoPosition);
}
« no previous file with comments | « src/ia32/full-codegen-ia32.cc ('k') | src/typing.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698