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

Unified Diff: src/compiler/ast-graph-builder.cc

Issue 1168093002: [strong] Implement strong mode restrictions on property access (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: rebase Created 5 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/code-stubs-hydrogen.cc ('k') | src/compiler/js-generic-lowering.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/compiler/ast-graph-builder.cc
diff --git a/src/compiler/ast-graph-builder.cc b/src/compiler/ast-graph-builder.cc
index 159536c2e1a8405ae2c8313eb0c467e3dfb67e21..f967a9775a067a55a29b8862053095e14b2c2df8 100644
--- a/src/compiler/ast-graph-builder.cc
+++ b/src/compiler/ast-graph-builder.cc
@@ -3459,7 +3459,7 @@ static inline Node* Record(JSTypeFeedbackTable* js_type_feedback, Node* node,
Node* AstGraphBuilder::BuildKeyedLoad(Node* object, Node* key,
const ResolvedFeedbackSlot& feedback) {
- const Operator* op = javascript()->LoadProperty(feedback);
+ const Operator* op = javascript()->LoadProperty(feedback, language_mode());
return Record(js_type_feedback_,
NewNode(op, object, key, GetFeedbackVector()), feedback.slot());
}
@@ -3468,8 +3468,8 @@ Node* AstGraphBuilder::BuildKeyedLoad(Node* object, Node* key,
Node* AstGraphBuilder::BuildNamedLoad(Node* object, Handle<Name> name,
const ResolvedFeedbackSlot& feedback,
ContextualMode mode) {
- const Operator* op =
- javascript()->LoadNamed(MakeUnique(name), feedback, mode);
+ const Operator* op = javascript()->LoadNamed(MakeUnique(name), feedback,
+ language_mode(), mode);
return Record(js_type_feedback_, NewNode(op, object, GetFeedbackVector()),
feedback.slot());
}
@@ -3494,8 +3494,9 @@ Node* AstGraphBuilder::BuildNamedSuperLoad(
Node* receiver, Node* home_object, Handle<Name> name,
const ResolvedFeedbackSlot& feedback) {
Node* name_node = jsgraph()->Constant(name);
- const Operator* op = javascript()->CallRuntime(Runtime::kLoadFromSuper, 3);
- Node* value = NewNode(op, receiver, home_object, name_node);
+ Node* language = jsgraph()->Constant(language_mode());
+ const Operator* op = javascript()->CallRuntime(Runtime::kLoadFromSuper, 4);
+ Node* value = NewNode(op, receiver, home_object, name_node, language);
return Record(js_type_feedback_, value, feedback.slot());
}
@@ -3503,9 +3504,10 @@ Node* AstGraphBuilder::BuildNamedSuperLoad(
Node* AstGraphBuilder::BuildKeyedSuperLoad(
Node* receiver, Node* home_object, Node* key,
const ResolvedFeedbackSlot& feedback) {
+ Node* language = jsgraph()->Constant(language_mode());
const Operator* op =
- javascript()->CallRuntime(Runtime::kLoadKeyedFromSuper, 3);
- Node* value = NewNode(op, receiver, home_object, key);
+ javascript()->CallRuntime(Runtime::kLoadKeyedFromSuper, 4);
+ Node* value = NewNode(op, receiver, home_object, key, language);
return Record(js_type_feedback_, value, feedback.slot());
}
« no previous file with comments | « src/code-stubs-hydrogen.cc ('k') | src/compiler/js-generic-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698