Index: src/full-codegen/x87/full-codegen-x87.cc |
diff --git a/src/full-codegen/x87/full-codegen-x87.cc b/src/full-codegen/x87/full-codegen-x87.cc |
index 5b4e39acb797f90911f59072dd439ac0cfe505bd..8d2114340d983a39a768926cd40449f33fbad9d4 100644 |
--- a/src/full-codegen/x87/full-codegen-x87.cc |
+++ b/src/full-codegen/x87/full-codegen-x87.cc |
@@ -2542,8 +2542,8 @@ |
context()->DropAndPlug(1, eax); |
} |
-void FullCodeGenerator::EmitResolvePossiblyDirectEval(Call* expr) { |
- int arg_count = expr->arguments()->length(); |
+ |
+void FullCodeGenerator::EmitResolvePossiblyDirectEval(int arg_count) { |
// Push copy of the first argument or undefined if it doesn't exist. |
if (arg_count > 0) { |
__ push(Operand(esp, arg_count * kPointerSize)); |
@@ -2557,8 +2557,8 @@ |
// Push the language mode. |
__ push(Immediate(Smi::FromInt(language_mode()))); |
- // Push the source position of the eval call. |
- __ push(Immediate(Smi::FromInt(expr->position()))); |
+ // Push the start position of the scope the calls resides in. |
+ __ push(Immediate(Smi::FromInt(scope()->start_position()))); |
// Do the runtime call. |
__ CallRuntime(Runtime::kResolvePossiblyDirectEval); |
@@ -2606,7 +2606,7 @@ |
void FullCodeGenerator::EmitPossiblyEvalCall(Call* expr) { |
- // In a call to eval, we first call Runtime_ResolvePossiblyDirectEval |
+ // In a call to eval, we first call RuntimeHidden_ResolvePossiblyDirectEval |
// to resolve the function we need to call. Then we call the resolved |
// function using the given arguments. |
ZoneList<Expression*>* args = expr->arguments(); |
@@ -2622,7 +2622,7 @@ |
// Push a copy of the function (found below the arguments) and |
// resolve eval. |
__ push(Operand(esp, (arg_count + 1) * kPointerSize)); |
- EmitResolvePossiblyDirectEval(expr); |
+ EmitResolvePossiblyDirectEval(arg_count); |
// Touch up the stack with the resolved function. |
__ mov(Operand(esp, (arg_count + 1) * kPointerSize), eax); |