| Index: src/ast/ast.h
|
| diff --git a/src/ast/ast.h b/src/ast/ast.h
|
| index 28004058f231dc30c93a7f26e9d1a2cf78dac17a..81a98b641d74498d8a7c554b451a2a1c5f48325e 100644
|
| --- a/src/ast/ast.h
|
| +++ b/src/ast/ast.h
|
| @@ -1679,8 +1679,6 @@ class VariableProxy final : public Expression {
|
| HoleCheckModeField::update(bit_field_, HoleCheckMode::kRequired);
|
| }
|
|
|
| - int end_position() const { return end_position_; }
|
| -
|
| // Bind this proxy to the variable var.
|
| void BindTo(Variable* var);
|
|
|
| @@ -1701,9 +1699,9 @@ class VariableProxy final : public Expression {
|
| private:
|
| friend class AstNodeFactory;
|
|
|
| - VariableProxy(Variable* var, int start_position, int end_position);
|
| + VariableProxy(Variable* var, int start_position);
|
| VariableProxy(const AstRawString* name, VariableKind variable_kind,
|
| - int start_position, int end_position);
|
| + int start_position);
|
| explicit VariableProxy(const VariableProxy* copy_from);
|
|
|
| static int parent_num_ids() { return Expression::num_ids(); }
|
| @@ -1717,10 +1715,6 @@ class VariableProxy final : public Expression {
|
| class HoleCheckModeField
|
| : public BitField<HoleCheckMode, IsNewTargetField::kNext, 1> {};
|
|
|
| - // Position is stored in the AstNode superclass, but VariableProxy needs to
|
| - // know its end position too (for error messages). It cannot be inferred from
|
| - // the variable name length because it can contain escapes.
|
| - int end_position_;
|
| FeedbackVectorSlot variable_feedback_slot_;
|
| union {
|
| const AstRawString* raw_name_; // if !is_resolved_
|
| @@ -3341,18 +3335,15 @@ class AstNodeFactory final BASE_EMBEDDED {
|
| }
|
|
|
| VariableProxy* NewVariableProxy(Variable* var,
|
| - int start_position = kNoSourcePosition,
|
| - int end_position = kNoSourcePosition) {
|
| - return new (zone_) VariableProxy(var, start_position, end_position);
|
| + int start_position = kNoSourcePosition) {
|
| + return new (zone_) VariableProxy(var, start_position);
|
| }
|
|
|
| VariableProxy* NewVariableProxy(const AstRawString* name,
|
| VariableKind variable_kind,
|
| - int start_position = kNoSourcePosition,
|
| - int end_position = kNoSourcePosition) {
|
| + int start_position = kNoSourcePosition) {
|
| DCHECK_NOT_NULL(name);
|
| - return new (zone_)
|
| - VariableProxy(name, variable_kind, start_position, end_position);
|
| + return new (zone_) VariableProxy(name, variable_kind, start_position);
|
| }
|
|
|
| // Recreates the VariableProxy in this Zone.
|
|
|