@@ -1379,7 +1379,7 @@ contributors:
1379
1379
MatchPattern[Yield, Await] :
1380
1380
`(` MatchPattern[?Yield, ?Await] `)`
1381
1381
PrimitivePattern
1382
- BindingPattern [?Yield, ?Await]
1382
+ VariableDeclarationPattern [?Yield, ?Await]
1383
1383
MemberExpressionPattern[?Yield, ?Await]
1384
1384
ObjectPattern[?Yield, ?Await]
1385
1385
ArrayPattern[?Yield, ?Await]
@@ -1435,9 +1435,9 @@ contributors:
1435
1435
</code></pre>
1436
1436
</emu-note>
1437
1437
<!-- endregion -->
1438
- <!-- #region BindingPattern -->
1438
+ <!-- #region VariableDeclarationPattern -->
1439
1439
<emu-grammar type="definition">
1440
- BindingPattern [Yield, Await] :
1440
+ VariableDeclarationPattern [Yield, Await] :
1441
1441
VarOrLetOrConst BindingIdentifier[?Yield, ?Await]
1442
1442
1443
1443
VarOrLetOrConst :
@@ -1687,13 +1687,14 @@ contributors:
1687
1687
</emu-note>
1688
1688
<emu-note type="editor">
1689
1689
<p>It is possible to add the following production.</p>
1690
- <emu-grammar type="definition" >
1690
+ <emu-grammar>
1691
1691
RelationalPattern[Yield, Await] :
1692
1692
`typeof` `==` PatternMatchingStringLikeExpression[?Yield, ?Await]
1693
1693
`typeof` `!=` PatternMatchingStringLikeExpression[?Yield, ?Await]
1694
1694
`typeof` `===` PatternMatchingStringLikeExpression[?Yield, ?Await]
1695
1695
`typeof` `!==` PatternMatchingStringLikeExpression[?Yield, ?Await]
1696
-
1696
+ </emu-grammar>
1697
+ <emu-grammar type="definition">
1697
1698
PatternMatchingStringLikeExpression[Yield, Await] :
1698
1699
StringLiteral
1699
1700
NoSubstitutionTemplate
@@ -1702,7 +1703,7 @@ contributors:
1702
1703
<p>
1703
1704
The recommended way to match a String is to use the <emu-xref href="#sec-string-%symbol.custommatcher%"
1704
1705
title></emu-xref>,
1705
- but it can be replaced. This production adds the ability to do the unforgeable `typeof` test.
1706
+ but it can be replaced by a custom implementation . This production adds the ability to do the unforgeable `typeof` test.
1706
1707
</p>
1707
1708
<pre><code class="javascript">
1708
1709
if (expr is { version: 2 or 3, value: String }) {}
@@ -1832,9 +1833,9 @@ contributors:
1832
1833
<li>It is a Syntax Error if |NoSubstitutionTemplate| Contains |NotEscapeSequence|.</li>
1833
1834
</ul>
1834
1835
<!-- #endregion -->
1835
- <!-- #region BindingPattern -->
1836
+ <!-- #region VariableDeclarationPattern -->
1836
1837
<emu-grammar>
1837
- BindingPattern : VarOrLetOrConst BindingIdentifier
1838
+ VariableDeclarationPattern : VarOrLetOrConst BindingIdentifier
1838
1839
</emu-grammar>
1839
1840
<ul>
1840
1841
<li>It is a Syntax Error if |VarOrLetOrConst| is |LetOrConst| and the StringValue of |BindingIdentifier| is *"let"*.</li>
@@ -2006,10 +2007,10 @@ contributors:
2006
2007
1. Return PrimitivePatternMatches of |PrimitivePattern| with argument _subject_.
2007
2008
</emu-alg>
2008
2009
<emu-grammar>
2009
- MatchPattern : BindingPattern
2010
+ MatchPattern : VariableDeclarationPattern
2010
2011
</emu-grammar>
2011
2012
<emu-alg>
2012
- 1. Return BindingPatternMatches of |BindingPattern | with argument _subject_.
2013
+ 1. Return VariableDeclarationPatternMatches of |VariableDeclarationPattern | with argument _subject_.
2013
2014
</emu-alg>
2014
2015
<emu-grammar>
2015
2016
MatchPattern : MemberExpressionPattern
@@ -2077,16 +2078,16 @@ contributors:
2077
2078
</emu-alg>
2078
2079
</emu-clause>
2079
2080
2080
- <emu-clause id="sec-binding -pattern-matches" type="sdo">
2081
+ <emu-clause id="sec-variable-declaration -pattern-matches" type="sdo">
2081
2082
<h1>
2082
- Runtime Semantics: BindingPatternMatches (
2083
+ Runtime Semantics: VariableDeclarationPatternMatches (
2083
2084
_subject_: an ECMAScript language value,
2084
2085
): a Boolean
2085
2086
</h1>
2086
2087
<dl class="header">
2087
2088
</dl>
2088
2089
<emu-grammar>
2089
- BindingPattern : VarOrLetOrConst BindingIdentifier
2090
+ VariableDeclarationPattern : VarOrLetOrConst BindingIdentifier
2090
2091
</emu-grammar>
2091
2092
<emu-alg>
2092
2093
1. TODO: This section is not written in the spec language yet.
@@ -3125,7 +3126,7 @@ contributors:
3125
3126
<h1>Patterns</h1>
3126
3127
<emu-prodref name="MatchPattern"></emu-prodref>
3127
3128
<emu-prodref name="PrimitivePattern"></emu-prodref>
3128
- <emu-prodref name="BindingPattern "></emu-prodref>
3129
+ <emu-prodref name="VariableDeclarationPattern "></emu-prodref>
3129
3130
<emu-prodref name="VarOrLetOrConst"></emu-prodref>
3130
3131
<emu-prodref name="MemberExpressionPattern"></emu-prodref>
3131
3132
<emu-prodref name="ObjectPattern"></emu-prodref>
0 commit comments