| Index: src/full-codegen/full-codegen.cc
|
| diff --git a/src/full-codegen/full-codegen.cc b/src/full-codegen/full-codegen.cc
|
| index c4d96454c48e824e142c74e0ab90816bbb838053..03f1b5137895cc44dc09cf1dea0afb3addbe4447 100644
|
| --- a/src/full-codegen/full-codegen.cc
|
| +++ b/src/full-codegen/full-codegen.cc
|
| @@ -952,7 +952,12 @@ void FullCodeGenerator::VisitWithStatement(WithStatement* stmt) {
|
| Comment cmnt(masm_, "[ WithStatement");
|
| SetStatementPosition(stmt);
|
|
|
| - VisitForStackValue(stmt->expression());
|
| + VisitForAccumulatorValue(stmt->expression());
|
| + Callable callable = CodeFactory::ToObject(isolate());
|
| + __ Move(callable.descriptor().GetRegisterParameter(0), result_register());
|
| + __ Call(callable.code(), RelocInfo::CODE_TARGET);
|
| + PrepareForBailoutForId(stmt->ToObjectId(), NO_REGISTERS);
|
| + __ Push(result_register());
|
| PushFunctionArgumentForContextAllocation();
|
| __ CallRuntime(Runtime::kPushWithContext, 2);
|
| StoreToFrameField(StandardFrameConstants::kContextOffset, context_register());
|
|
|