@@ -33,15 +33,13 @@ <h1>Spread Properties</h1>
33
33
34
34
<h2 >Syntax</h2 >
35
35
36
- <emu-production name =" PropertyDefinition" params =" Yield" >
37
- <emu-rhs ><emu-nt params =" ?Yield" >IdentifierReference</emu-nt ></emu-rhs >
38
- <emu-rhs ><emu-nt params =" ?Yield" >CoverInitializedName</emu-nt ></emu-rhs >
39
- <emu-rhs ><emu-nt params =" ?Yield" >PropertyName</emu-nt ><emu-t >:</emu-t ><emu-nt params =" In, ?Yield" >AssignmentExpression</emu-nt ></emu-rhs >
40
- <emu-rhs ><emu-nt params =" ?Yield" >MethodDefinition</emu-nt ></emu-rhs >
41
- <ins class =" block" >
42
- <emu-rhs ><emu-t >...</emu-t ><emu-nt params =" In, ?Yield" >AssignmentExpression</emu-nt ></emu-rhs >
43
- </ins >
44
- </emu-production >
36
+ <emu-grammar >
37
+ PropertyDefinition [Yield , Await ] :
38
+ IdentifierReference [? Yield , ? Await ]
39
+ CoverInitializedName [? Yield , ? Await ]
40
+ PropertyName [? Yield , ? Await ]
41
+ <ins class="block"> ` ...` AssignmentExpression [In, ? Yield , ? Await ]</ins>
42
+ </emu-grammar >
45
43
46
44
<emu-clause id =" Spread-RuntimeSemantics-PropertyDefinitionEvaluation" >
47
45
<h1 >Runtime Semantics: PropertyDefinitionEvaluation</h1 >
@@ -66,30 +64,27 @@ <h1>Rest Properties</h1>
66
64
67
65
<h2 >Syntax</h2 >
68
66
69
- <emu-production name = " ObjectAssignmentPattern " params = " Yield " >
70
- < emu-rhs >< emu-t >{</ emu-t >< ins >< emu-nt params = " ? Yield" optional >AssignmentRestProperty</ emu-nt ></ ins >< emu-t >}</ emu-t ></ emu-rhs >
71
- < emu-rhs >< emu-t >{</ emu-t >< emu-nt params = " ?Yield" >AssignmentPropertyList</ emu-nt >< emu-t >}</ emu-t ></ emu-rhs >
72
- < emu-rhs >< emu-t >{</ emu-t >< emu-nt params = " ?Yield" >AssignmentPropertyList</ emu-nt >< emu-t >,</ emu-t >< ins >< emu-nt params = " ?Yield " optional >AssignmentRestProperty</ emu-nt ></ ins >< emu-t >}</ emu-t ></ emu-rhs >
73
- </ emu-production >
67
+ <emu-grammar >
68
+ ObjectAssignmentPattern [ Yield , Await ] :
69
+ ` { ` <ins> AssignmentRestProperty [ ? Yield , ? Await ] ? </ins> ` } `
70
+ ` { ` AssignmentPropertyList [ ? Yield , ? Await ] ` } `
71
+ ` { ` AssignmentPropertyList [ ? Yield , ? Await ] ` , ` <ins> AssignmentRestProperty [ ? Yield , ? Await ] ? </ins> ` } `
74
72
75
- <ins class =" block" >
76
- <emu-production name =" AssignmentRestProperty" params =" Yield" >
77
- <emu-rhs ><emu-t >...</emu-t ><emu-nt params =" ?Yield" >DestructuringAssignmentTarget</emu-nt ></emu-rhs >
78
- </emu-production >
79
- </ins >
73
+ <ins class="block">
74
+ AssignmentRestProperty [Yield , Await ] :
75
+ ` ...` DestructuringAssignmentTarget [Yield, Await]
76
+ </ins>
80
77
81
- <emu-production name =" ObjectBindingPattern" params =" Yield" >
82
- <emu-rhs ><emu-t >{</emu-t ><ins ><emu-nt params =" ?Yield" optional >BindingRestProperty</emu-nt ></ins ><emu-t >}</emu-t ></emu-rhs >
83
- <emu-rhs ><emu-t >{</emu-t ><emu-nt params =" ?Yield" >BindingPropertyList</emu-nt ><emu-t >}</emu-t ></emu-rhs >
84
- <emu-rhs ><emu-t >{</emu-t ><emu-nt params =" ?Yield" >BindingPropertyList</emu-nt ><emu-t >,</emu-t ><ins ><emu-nt params =" ?Yield" optional >BindingRestProperty</emu-nt ></ins ><emu-t >}</emu-t ></emu-rhs >
85
- </emu-production >
78
+ ObjectBindingPattern [Yield , Await ] :
79
+ ` {` <ins> BindingRestProperty [? Yield , ? Await ]? </ins> ` }`
80
+ ` {` BindingPropertyList [? Yield , ? Await ] ` }`
81
+ ` {` BindingPropertyList [? Yield , ? Await ] ` ,` <ins> BindingRestProperty [? Yield , ? Await ]? </ins> ` }`
86
82
87
- <ins class =" block" >
88
- <emu-production name =" BindingRestProperty" params =" Yield" >
89
- <emu-rhs ><emu-t >...</emu-t ><emu-nt params =" ?Yield" >BindingIdentifier</emu-nt ></emu-rhs >
90
- <emu-rhs ><emu-t >...</emu-t ><emu-nt params =" ?Yield" >BindingPattern</emu-nt ></emu-rhs >
91
- </emu-production >
92
- </ins >
83
+ <ins class="block">
84
+ BindingRestProperty [Yield , Await ] :
85
+ ` ...` BindingIdentifier [? Yield , ? Await ]
86
+ </ins>
87
+ </emu-grammar >
93
88
94
89
<emu-clause id =" Rest-RuntimeSemantics-DestructuringAssignmentEvaluation" >
95
90
<h1 >Runtime Semantics: DestructuringAssignmentEvaluation</h1 >
@@ -177,7 +172,7 @@ <h1>Runtime Semantics: PropertyDestructuringAssignmentEvaluation</h1>
177
172
<h1 >Runtime Semantics: RestDestructuringAssignmentEvaluation</h1 >
178
173
<p >With parameters _value_ and _excludedNames_ .</p >
179
174
180
- <emu-grammar >AssignmentRestProperty [Yield ] : ` ...` DestructuringAssignmentTarget </emu-grammar >
175
+ <emu-grammar >AssignmentRestProperty [Yield , Await ] : ` ...` DestructuringAssignmentTarget </emu-grammar >
181
176
<emu-alg >
182
177
1. If | DestructuringAssignmentTarget | is neither an | ObjectLiteral | nor an | ArrayLiteral | , then
183
178
1. Let _lref_ be the result of evaluating | DestructuringAssignmentTarget | .
@@ -187,7 +182,7 @@ <h1>Runtime Semantics: RestDestructuringAssignmentEvaluation</h1>
187
182
1. ReturnIfAbrupt(_assignStatus_ ).
188
183
1. If | DestructuringAssignmentTarget | is neither an | ObjectLiteral | nor an | ArrayLiteral | , then
189
184
1. Return PutValue(_lref_ , _restObj_ ).
190
- 1. Let _nestedAssignmentPattern_ be the parse of the source text corresponding to | DestructuringAssignmentTarget | using either | AssignmentPattern | or | AssignmentPattern [ Yield ] | as the goal symbol depending upon whether this | AssignmentRestProperty | has the < sub >[Yield]</ sub > parameter .
185
+ 1. Let _nestedAssignmentPattern_ be the parse of the source text corresponding to | DestructuringAssignmentTarget | using either | AssignmentPattern [ ? Yield , ? Await ] | as the goal symbol, adopting the parameter values from | AssignmentRestProperty | .
191
186
1. Return the result of performing DestructuringAssignmentEvaluation of _nestedAssignmentPattern_ with _restObj_ as the argument.
192
187
</emu-alg >
193
188
</emu-clause >
@@ -284,14 +279,6 @@ <h1>Runtime Semantics: RestBindingInitialization</h1>
284
279
1. If _environment_ is *undefined* , return PutValue(_lhs_ , _restObj_ ).
285
280
1. Return InitializeReferencedBinding(_lhs_ , _restObj_ ).
286
281
</emu-alg >
287
-
288
- <emu-grammar >BindingRestProperty : ` ...` BindingPattern </emu-grammar >
289
- <emu-alg >
290
- 1. Let _restObj_ be ObjectCreate(%ObjectPrototype%).
291
- 1. Let _assignStatus_ be CopyDataProperties(_restObj_ , _value_ , _excludedNames_ ).
292
- 1. ReturnIfAbrupt(_assignStatus_ ).
293
- 1. Return the result of performing BindingInitialization of | BindingPattern | with _restObj_ and _environment_ as the arguments.
294
- </emu-alg >
295
282
</emu-clause >
296
283
</ins >
297
284
</emu-clause >
0 commit comments