| Index: src/ast.h
|
| diff --git a/src/ast.h b/src/ast.h
|
| index 0882b250ffde424f2f86925d1416c4fa54288f54..fb19e8e09bf98b2b58c048edc7b60f7607070875 100644
|
| --- a/src/ast.h
|
| +++ b/src/ast.h
|
| @@ -1447,12 +1447,14 @@ class ObjectLiteralProperty V8_FINAL : public ZoneObject {
|
| COMPUTED, // Property with computed value (execution time).
|
| MATERIALIZED_LITERAL, // Property value is a materialized literal.
|
| GETTER, SETTER, // Property is an accessor function.
|
| - PROTOTYPE // Property is __proto__.
|
| + PROTOTYPE, // Property is __proto__.
|
| + COMPUTED_NAME // Property with computed name.
|
| };
|
|
|
| - ObjectLiteralProperty(Zone* zone, Literal* key, Expression* value);
|
| + ObjectLiteralProperty(Zone* zone, Expression* key, Expression* value,
|
| + bool is_computed_name);
|
|
|
| - Literal* key() { return key_; }
|
| + Expression* key() { return key_; }
|
| Expression* value() { return value_; }
|
| Kind kind() { return kind_; }
|
|
|
| @@ -1470,10 +1472,10 @@ class ObjectLiteralProperty V8_FINAL : public ZoneObject {
|
| template<class> friend class AstNodeFactory;
|
|
|
| ObjectLiteralProperty(Zone* zone, bool is_getter, FunctionLiteral* value);
|
| - void set_key(Literal* key) { key_ = key; }
|
| + void set_key(Expression* key) { key_ = key; }
|
|
|
| private:
|
| - Literal* key_;
|
| + Expression* key_;
|
| Expression* value_;
|
| Kind kind_;
|
| bool emit_store_;
|
| @@ -3154,9 +3156,11 @@ class AstNodeFactory V8_FINAL BASE_EMBEDDED {
|
| VISIT_AND_RETURN(ObjectLiteral, lit)
|
| }
|
|
|
| - ObjectLiteral::Property* NewObjectLiteralProperty(Literal* key,
|
| - Expression* value) {
|
| - return new(zone_) ObjectLiteral::Property(zone_, key, value);
|
| + ObjectLiteral::Property* NewObjectLiteralProperty(Expression* key,
|
| + Expression* value,
|
| + bool is_computed_name) {
|
| + return new(zone_) ObjectLiteral::Property(zone_, key, value,
|
| + is_computed_name);
|
| }
|
|
|
| ObjectLiteral::Property* NewObjectLiteralProperty(bool is_getter,
|
|
|