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

Unified Diff: src/full-codegen/ppc/full-codegen-ppc.cc

Issue 1382513003: Test for var declarations in eval which conflict with let (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: mask out eval bit Created 5 years, 2 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/full-codegen/mips64/full-codegen-mips64.cc ('k') | src/full-codegen/x64/full-codegen-x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/full-codegen/ppc/full-codegen-ppc.cc
diff --git a/src/full-codegen/ppc/full-codegen-ppc.cc b/src/full-codegen/ppc/full-codegen-ppc.cc
index 8be26200276364896e54c8141dd67c5e6b1ca64f..846c854f6ce934e081c1fcb55dfe9d1e5eb4bba7 100644
--- a/src/full-codegen/ppc/full-codegen-ppc.cc
+++ b/src/full-codegen/ppc/full-codegen-ppc.cc
@@ -817,10 +817,10 @@ void FullCodeGenerator::VisitVariableDeclaration(
__ LoadSmiLiteral(r3, Smi::FromInt(0)); // Indicates no initial value.
__ Push(r5, r3);
}
- __ CallRuntime(IsImmutableVariableMode(mode)
- ? Runtime::kDeclareReadOnlyLookupSlot
- : Runtime::kDeclareLookupSlot,
- 2);
+ __ LoadSmiLiteral(
+ r3, Smi::FromInt(variable->DeclarationPropertyAttributes()));
+ __ Push(r3);
+ __ CallRuntime(Runtime::kDeclareLookupSlot, 3);
break;
}
}
@@ -871,7 +871,10 @@ void FullCodeGenerator::VisitFunctionDeclaration(
__ Push(r5);
// Push initial value for function declaration.
VisitForStackValue(declaration->fun());
- __ CallRuntime(Runtime::kDeclareLookupSlot, 2);
+ __ LoadSmiLiteral(
+ r5, Smi::FromInt(variable->DeclarationPropertyAttributes()));
+ __ Push(r5);
+ __ CallRuntime(Runtime::kDeclareLookupSlot, 3);
break;
}
}
« no previous file with comments | « src/full-codegen/mips64/full-codegen-mips64.cc ('k') | src/full-codegen/x64/full-codegen-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698