Debian Codegraph @

js/src/tests/test262/language/expressions/arrow-function/dflt-params-rest.js

raw
1 // |reftest| error:SyntaxError
2 // This file was procedurally generated from the following sources:
3 // - src/function-forms/dflt-params-rest.case
4 // - src/function-forms/syntax/arrow-function.template
5 /*---
6 description: RestParameter does not support an initializer (arrow function expression)
7 esid: sec-arrow-function-definitions-runtime-semantics-evaluation
8 features: [default-parameters]
9 flags: [generated]
10 negative:
11 phase: parse
12 type: SyntaxError
13 info: |
14 ArrowFunction : ArrowParameters => ConciseBody
15
16 [...]
17 4. Let closure be FunctionCreate(Arrow, parameters, ConciseBody, scope, strict).
18 [...]
19
20 9.2.1 [[Call]] ( thisArgument, argumentsList)
21
22 [...]
23 7. Let result be OrdinaryCallEvaluateBody(F, argumentsList).
24 [...]
25
26 9.2.1.3 OrdinaryCallEvaluateBody ( F, argumentsList )
27
28 1. Let status be FunctionDeclarationInstantiation(F, argumentsList).
29 [...]
30
31 9.2.12 FunctionDeclarationInstantiation(func, argumentsList)
32
33 [...]
34 23. Let iteratorRecord be Record {[[iterator]]:
35 CreateListIterator(argumentsList), [[done]]: false}.
36 24. If hasDuplicates is true, then
37 [...]
38 25. Else,
39 b. Let formalStatus be IteratorBindingInitialization for formals with
40 iteratorRecord and env as arguments.
41 [...]
42
43 14.1 Function Definitions
44
45 Syntax
46
47 FunctionRestParameter[Yield] :
48
49 BindingRestElement[?Yield]
50
51 13.3.3 Destructuring Binding Patterns
52
53 Syntax
54
55 BindingRestElement[Yield] :
56
57 ...BindingIdentifier[?Yield]
58 ...BindingPattern[?Yield]
59
60 ---*/
61 $DONOTEVALUATE();
62
63 0, (...x = []) => {
64
65 };