Chromium Code Reviews| Index: runtime/vm/ast.h |
| =================================================================== |
| --- runtime/vm/ast.h (revision 14146) |
| +++ runtime/vm/ast.h (working copy) |
| @@ -1114,14 +1114,22 @@ |
| class LoadIndexedNode : public AstNode { |
| public: |
| - LoadIndexedNode(intptr_t token_pos, AstNode* array, AstNode* index) |
| - : AstNode(token_pos), array_(array), index_expr_(index) { |
| + LoadIndexedNode(intptr_t token_pos, |
| + AstNode* array, |
| + AstNode* index, |
| + const Class& super_class) |
| + : AstNode(token_pos), |
| + array_(array), |
| + index_expr_(index), |
| + super_class_(super_class) { |
| ASSERT(array_ != NULL); |
| ASSERT(index_expr_ != NULL); |
|
regis
2012/10/26 22:04:37
ASSERT(super_class_.IsZoneHandle());
hausner
2012/10/26 22:25:14
Done.
|
| } |
| AstNode* array() const { return array_; } |
| AstNode* index_expr() const { return index_expr_; } |
| + const Class& super_class() const { return super_class_; } |
| + bool IsSuperLoad() const { return !super_class_.IsNull(); } |
| virtual void VisitChildren(AstNodeVisitor* visitor) const { |
| array()->Visit(visitor); |
| @@ -1135,6 +1143,7 @@ |
| private: |
| AstNode* array_; |
| AstNode* index_expr_; |
| + const Class& super_class_; |
| DISALLOW_IMPLICIT_CONSTRUCTORS(LoadIndexedNode); |
| }; |
| @@ -1142,8 +1151,15 @@ |
| class StoreIndexedNode : public AstNode { |
| public: |
| StoreIndexedNode(intptr_t token_pos, |
| - AstNode* array, AstNode* index, AstNode* value) |
| - : AstNode(token_pos), array_(array), index_expr_(index), value_(value) { |
| + AstNode* array, |
| + AstNode* index, |
| + AstNode* value, |
| + const Class& super_class) |
| + : AstNode(token_pos), |
| + array_(array), |
| + index_expr_(index), |
| + value_(value), |
| + super_class_(super_class) { |
| ASSERT(array_ != NULL); |
| ASSERT(index_expr_ != NULL); |
| ASSERT(value_ != NULL); |
|
regis
2012/10/26 22:04:37
ASSERT(super_class_.IsZoneHandle());
hausner
2012/10/26 22:25:14
Done.
|
| @@ -1152,6 +1168,8 @@ |
| AstNode* array() const { return array_; } |
| AstNode* index_expr() const { return index_expr_; } |
| AstNode* value() const { return value_; } |
| + const Class& super_class() const { return super_class_; } |
| + bool IsSuperStore() const { return !super_class_.IsNull(); } |
| virtual void VisitChildren(AstNodeVisitor* visitor) const { |
| array()->Visit(visitor); |
| @@ -1165,6 +1183,7 @@ |
| AstNode* array_; |
| AstNode* index_expr_; |
| AstNode* value_; |
| + const Class& super_class_; |
| DISALLOW_IMPLICIT_CONSTRUCTORS(StoreIndexedNode); |
| }; |