Index: src/ast.h |
diff --git a/src/ast.h b/src/ast.h |
index 80be15892e6cb0578cf65341d889164bab7c994e..f695e1233340d274df2b5aff68398c2623857c31 100644 |
--- a/src/ast.h |
+++ b/src/ast.h |
@@ -3390,7 +3390,16 @@ class AstNodeFactory FINAL BASE_EMBEDDED { |
Call* NewCall(Expression* expression, |
ZoneList<Expression*>* arguments, |
int pos) { |
- Call* call = new (zone_) Call(zone_, expression, arguments, pos, id_gen_); |
+ SuperReference* super_ref = expression->AsSuperReference(); |
+ Call* call; |
+ if (super_ref != NULL) { |
+ Literal* constructor = |
+ NewStringLiteral(ast_value_factory_->constructor_string(), pos); |
+ Property* superConstructor = NewProperty(super_ref, constructor, pos); |
+ call = new (zone_) Call(zone_, superConstructor, arguments, pos, id_gen_); |
+ } else { |
+ call = new (zone_) Call(zone_, expression, arguments, pos, id_gen_); |
+ } |
VISIT_AND_RETURN(Call, call) |
} |