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

Unified Diff: src/ast.h

Issue 458813002: Prototype implementation of GET_OWN_PROPERTY intrinsic. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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/accessors.cc ('k') | src/builtins.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ast.h
diff --git a/src/ast.h b/src/ast.h
index e18fdc79c71ffad36d3af96e65389775b039b6c9..a874addd9aaf318ff2ae0f1c055082733cba52c9 100644
--- a/src/ast.h
+++ b/src/ast.h
@@ -1705,6 +1705,7 @@ class Property V8_FINAL : public Expression, public FeedbackSlotInterface {
bool HasNoTypeInformation() {
return is_uninitialized_;
}
+ bool IsOwnProperty() const { return is_own_property_; }
void set_is_uninitialized(bool b) { is_uninitialized_ = b; }
void set_is_string_access(bool b) { is_string_access_ = b; }
void mark_for_call() { is_for_call_ = true; }
@@ -1728,7 +1729,10 @@ class Property V8_FINAL : public Expression, public FeedbackSlotInterface {
property_feedback_slot_(kInvalidFeedbackSlot),
is_for_call_(false),
is_uninitialized_(false),
- is_string_access_(false) {}
+ is_string_access_(false),
+ is_own_property_(false) {}
+
+ void set_is_own_property(bool b) { is_own_property_ = b; }
private:
Expression* obj_;
@@ -1740,6 +1744,7 @@ class Property V8_FINAL : public Expression, public FeedbackSlotInterface {
bool is_for_call_ : 1;
bool is_uninitialized_ : 1;
bool is_string_access_ : 1;
+ bool is_own_property_ : 1;
};
@@ -3346,6 +3351,12 @@ class AstNodeFactory V8_FINAL BASE_EMBEDDED {
VISIT_AND_RETURN(Property, prop)
}
+ Property* NewOwnProperty(Expression* obj, Expression* key, int pos) {
+ Property* prop = new(zone_) Property(zone_, obj, key, pos);
+ prop->set_is_own_property(true);
+ VISIT_AND_RETURN(Property, prop);
+ }
+
Call* NewCall(Expression* expression,
ZoneList<Expression*>* arguments,
int pos) {
« no previous file with comments | « src/accessors.cc ('k') | src/builtins.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698