Index: src/parsing/parser.cc |
diff --git a/src/parsing/parser.cc b/src/parsing/parser.cc |
index 8310ad948c543de2cfa10689062e10e1a1106496..3751acba6bd4be2c24628625f2fd5c29765c2b53 100644 |
--- a/src/parsing/parser.cc |
+++ b/src/parsing/parser.cc |
@@ -4470,9 +4470,13 @@ ZoneList<Statement*>* Parser::ParseEagerFunctionBody( |
{ |
ZoneList<Expression*>* arguments = |
- new (zone()) ZoneList<Expression*>(0, zone()); |
+ new (zone()) ZoneList<Expression*>(2, zone()); |
+ arguments->Add(factory()->NewThisFunction(pos), zone()); |
+ arguments->Add( |
+ ThisExpression(scope_, factory(), RelocInfo::kNoPosition), zone()); |
CallRuntime* allocation = factory()->NewCallRuntime( |
Runtime::kCreateJSGeneratorObject, arguments, pos); |
+ |
VariableProxy* init_proxy = factory()->NewVariableProxy( |
function_state_->generator_object_variable()); |
Assignment* assignment = factory()->NewAssignment( |