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 866533003: Use FunctionLiteral for class constructor (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 11 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 | « no previous file | src/parser.cc » ('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 74d6461cec1cdec8a0157f0ab422d233218e036d..dd4941673f7bf164c1285778ef46a20fba007bf1 100644
--- a/src/ast.h
+++ b/src/ast.h
@@ -2621,7 +2621,7 @@ class ClassLiteral FINAL : public Expression {
Scope* scope() const { return scope_; }
VariableProxy* class_variable_proxy() const { return class_variable_proxy_; }
Expression* extends() const { return extends_; }
- Expression* constructor() const { return constructor_; }
+ FunctionLiteral* constructor() const { return constructor_; }
ZoneList<Property*>* properties() const { return properties_; }
int start_position() const { return position(); }
int end_position() const { return end_position_; }
@@ -2634,7 +2634,7 @@ class ClassLiteral FINAL : public Expression {
protected:
ClassLiteral(Zone* zone, const AstRawString* name, Scope* scope,
VariableProxy* class_variable_proxy, Expression* extends,
- Expression* constructor, ZoneList<Property*>* properties,
+ FunctionLiteral* constructor, ZoneList<Property*>* properties,
int start_position, int end_position)
: Expression(zone, start_position),
raw_name_(name),
@@ -2653,7 +2653,7 @@ class ClassLiteral FINAL : public Expression {
Scope* scope_;
VariableProxy* class_variable_proxy_;
Expression* extends_;
- Expression* constructor_;
+ FunctionLiteral* constructor_;
ZoneList<Property*>* properties_;
int end_position_;
};
@@ -3496,7 +3496,7 @@ class AstNodeFactory FINAL BASE_EMBEDDED {
ClassLiteral* NewClassLiteral(const AstRawString* name, Scope* scope,
VariableProxy* proxy, Expression* extends,
- Expression* constructor,
+ FunctionLiteral* constructor,
ZoneList<ObjectLiteral::Property*>* properties,
int start_position, int end_position) {
return new (zone_)
« no previous file with comments | « no previous file | src/parser.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698