Fix arrow function lexical arguments binding, allow rest + arguments

Issue #1547
This commit is contained in:
janekptacijarabaci
2017-12-18 13:22:21 +01:00
committed by Roy Tam
parent fd05ca22e4
commit 7aaedab9c0
18 changed files with 137 additions and 137 deletions
-7
View File
@@ -65,13 +65,6 @@ SetSourceMap(ExclusiveContext* cx, TokenStream& tokenStream, ScriptSource* ss)
static bool
CheckArgumentsWithinEval(JSContext* cx, Parser<FullParseHandler>& parser, HandleFunction fun)
{
if (fun->hasRest()) {
// It's an error to use |arguments| in a function that has a rest
// parameter.
parser.report(ParseError, false, nullptr, JSMSG_ARGUMENTS_AND_REST);
return false;
}
RootedScript script(cx, fun->getOrCreateScript(cx));
if (!script)
return false;