| Index: src/preparser.h
|
| diff --git a/src/preparser.h b/src/preparser.h
|
| index 828f284c1648717b073bf125a54cb64a65ab6293..94f42797740cd27bc31726dd03341fee360a305d 100644
|
| --- a/src/preparser.h
|
| +++ b/src/preparser.h
|
| @@ -1044,6 +1044,7 @@ class PreParserTraits {
|
| bool is_generator,
|
| int function_token_position,
|
| FunctionLiteral::FunctionType type,
|
| + FunctionLiteral::ArityRestriction arity_restriction,
|
| bool* ok);
|
|
|
| private:
|
| @@ -1173,6 +1174,7 @@ class PreParser : public ParserBase<PreParserTraits> {
|
| bool is_generator,
|
| int function_token_pos,
|
| FunctionLiteral::FunctionType function_type,
|
| + FunctionLiteral::ArityRestriction arity_restriction,
|
| bool* ok);
|
| void ParseLazyFunctionLiteralBody(bool* ok);
|
|
|
| @@ -1552,9 +1554,9 @@ typename ParserBase<Traits>::ExpressionT ParserBase<Traits>::ParseObjectLiteral(
|
| false, // reserved words are allowed here
|
| false, // not a generator
|
| RelocInfo::kNoPosition, FunctionLiteral::ANONYMOUS_EXPRESSION,
|
| + is_getter ? FunctionLiteral::GETTER_ARITY
|
| + : FunctionLiteral::SETTER_ARITY,
|
| CHECK_OK);
|
| - // Allow any number of parameters for compatibilty with JSC.
|
| - // Specification only allows zero parameters for get and one for set.
|
| typename Traits::Type::ObjectLiteralProperty property =
|
| factory()->NewObjectLiteralProperty(is_getter, value, next_pos);
|
| if (this->IsBoilerplateProperty(property)) {
|
| @@ -2056,6 +2058,7 @@ ParserBase<Traits>::ParseMemberExpression(bool* ok) {
|
| is_generator,
|
| function_token_position,
|
| function_type,
|
| + FunctionLiteral::NORMAL_ARITY,
|
| CHECK_OK);
|
| } else {
|
| result = ParsePrimaryExpression(CHECK_OK);
|
|
|