Commit 3efce1c7 authored by mythria's avatar mythria Committed by Commit bot

[Interpreted] Throws an error if rest parameters are used.

Throws an error if rest parameters are used. This feature is not
yet supported in interpreter.

BUG=v8:4280
LOG=N

Review URL: https://codereview.chromium.org/1561603002

Cr-Commit-Position: refs/heads/master@{#33120}
parent b4583c04
......@@ -473,6 +473,12 @@ void BytecodeGenerator::MakeBytecodeBody() {
// Build the arguments object if it is used.
VisitArgumentsObject(scope()->arguments());
// TODO(mythria): Build rest arguments array if it is used.
int rest_index;
if (scope()->rest_parameter(&rest_index)) {
UNIMPLEMENTED();
}
// Build assignment to {.this_function} variable if it is used.
VisitThisFunctionVariable(scope()->this_function_var());
......
......@@ -705,6 +705,7 @@
'language/object-literal/method': [SKIP],
'language/object-literal/setter': [SKIP],
'language/rest-parameters/arrow-function': [SKIP],
'language/rest-parameters/expected-argument-count': [SKIP],
'language/rest-parameters/no-alias-arguments': [SKIP],
'language/rest-parameters/rest-index': [SKIP],
'language/rest-parameters/rest-parameters-apply': [SKIP],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment