Atom
With parameter _direction_.
- The production Atom :: `.` evaluates as follows:
+ The production Atom ::! `.` evaluates as follows:
1. Let _A_ be the CharSet of all characters.
1. If _DotAll_ is not *true*, then
1. Remove from _A_ all characters corresponding to a code point on the right-hand side of the |LineTerminator| production.
1. Return ! CharacterSetMatcher(_A_, *false*, _direction_).
- The production Atom :: `\` AtomEscape evaluates as follows:
+ The production Atom ::! `\` AtomEscape evaluates as follows:
1. Return the Matcher that is the result of evaluating |AtomEscape| with argument _direction_.
- The production Atom :: `\` [lookahead == `c`] evaluates as follows:
+ The production Atom ::! `\` [lookahead == `c`] evaluates as follows:
1. Let _A_ be the CharSet containing the single character `\\` U+005C (REVERSE SOLIDUS).
- 1. Call CharacterSetMatcher(_A_, *false*, _direction_) and return its Matcher result.
+ 1. Return ! CharacterSetMatcher(_A_, *false*, _direction_).
- The production Atom :: CharacterClass evaluates as follows:
+ The production Atom ::! CharacterClass evaluates as follows:
1. Evaluate |CharacterClass| to obtain a CharSet _A_ and a Boolean _invert_.
1. Return ! CharacterSetMatcher(_A_, _invert_, _direction_).
- The production Atom :: `(` GroupSpecifier Disjunction `)` evaluates as follows:
+ The production Atom ::! `(` GroupSpecifier Disjunction `)` evaluates as follows:
1. Evaluate |Disjunction| with argument _direction_ to obtain a Matcher _m_.
- 1. Let _parenIndex_ be the number of left-capturing parentheses in the entire regular expression that occur to the left of this |Atom|. This is the total number of Atom :: `(` GroupSpecifier Disjunction `)` Parse Nodes prior to or enclosing this |Atom|.
+ 1. Let _parenIndex_ be the number of left-capturing parentheses in the entire regular expression that occur to the left of this |Atom|. This is the total number of Atom ::! `(` GroupSpecifier Disjunction `)` Parse Nodes prior to or enclosing this |Atom|.
1. Return a new Matcher with parameters (_x_, _c_) that captures _direction_, _m_, and _parenIndex_ and performs the following steps when called:
1. Assert: _x_ is a State.
1. Assert: _c_ is a Continuation.
@@ -31379,11 +31369,11 @@ Atom
1. Return _c_(_z_).
1. Return _m_(_x_, _d_).
- The production Atom :: `(` `?` `:` Disjunction `)` evaluates as follows:
+ The production Atom ::! `(` `?` `:` Disjunction `)` evaluates as follows:
1. Return the Matcher that is the result of evaluating |Disjunction| with argument _direction_.
- The production Atom :: PatternCharacter evaluates as follows:
+ The production Atom ::! PatternCharacter evaluates as follows:
1. Let _ch_ be the character matched by |PatternCharacter|.
1. Let _A_ be a one-element CharSet containing the character _ch_.
@@ -31543,7 +31533,7 @@ NonemptyClassRanges
Runtime Semantics: CharacterRangeOrUnion ( _A_, _B_ )
- The abstract operation CharacterRangeOrUnion takes two CharSet parameters _A_ and _B_ and performs the following steps:
+ The abstract operation CharacterRangeOrUnion takes arguments _A_ (a CharSet) and _B_ (a CharSet). It performs the following steps when called:
1. If _Unicode_ is *false*, then
1. If _A_ does not contain exactly one character or _B_ does not contain exactly one character, then
@@ -31613,15 +31603,15 @@ ClassAtom
ClassAtomNoDash
- The production ClassAtomNoDash :: SourceCharacter but not one of `\` or `]` or `-` evaluates as follows:
+ The production ClassAtomNoDash ::! SourceCharacter but not one of `\` or `]` or `-` evaluates as follows:
1. Return the CharSet containing the character matched by |SourceCharacter|.
- The production ClassAtomNoDash :: `\` ClassEscape evaluates as follows:
+ The production ClassAtomNoDash ::! `\` ClassEscape evaluates as follows:
1. Return the CharSet that is the result of evaluating |ClassEscape|.
- The production ClassAtomNoDash :: `\` [lookahead == `c`] evaluates as follows:
+ The production ClassAtomNoDash ::! `\` [lookahead == `c`] evaluates as follows:
1. Return the CharSet containing the single character `\\` U+005C (REVERSE SOLIDUS).
@@ -31632,13 +31622,13 @@ ClassAtomNoDash
ClassEscape
The |ClassEscape| productions evaluate as follows:
- ClassEscape :: `b`
+ ClassEscape ::! `b`
- ClassEscape :: `-`
+ ClassEscape ::! `-`
- ClassEscape :: `c` ClassControlLetter
+ ClassEscape ::! `c` ClassControlLetter
- ClassEscape :: CharacterEscape
+ ClassEscape ::! CharacterEscape
1. Let _cv_ be the CharacterValue of this |ClassEscape|.
@@ -31646,7 +31636,7 @@ ClassEscape
1. Return the CharSet containing the single character _c_.
- ClassEscape :: CharacterClassEscape
+ ClassEscape ::! CharacterClassEscape
1. Return the CharSet that is the result of evaluating |CharacterClassEscape|.
@@ -31659,13 +31649,13 @@ ClassEscape
AtomEscape
With parameter _direction_.
- The production AtomEscape :: DecimalEscape evaluates as follows:
+ The production AtomEscape ::! DecimalEscape evaluates as follows:
1. Evaluate |DecimalEscape| to obtain an integer _n_.
1. Assert: _n_ ≤ _NcapturingParens_.
1. Return ! BackreferenceMatcher(_n_, _direction_).
- The production AtomEscape :: CharacterClassEscape evaluates as follows:
+ The production AtomEscape ::! CharacterClassEscape evaluates as follows:
1. Evaluate |CharacterClassEscape| to obtain a CharSet _A_.
1. Return ! CharacterSetMatcher(_A_, *false*, _direction_).
@@ -31673,17 +31663,17 @@ AtomEscape
An escape sequence of the form `\\` followed by a non-zero decimal number _n_ matches the result of the _n_th set of capturing parentheses (). It is an error if the regular expression has fewer than _n_ capturing parentheses. If the regular expression has _n_ or more capturing parentheses but the _n_th one is *undefined* because it has not captured anything, then the backreference always succeeds.
- The production AtomEscape :: CharacterEscape evaluates as follows:
+ The production AtomEscape ::! CharacterEscape evaluates as follows:
1. Evaluate |CharacterEscape| to obtain a character _ch_.
1. Let _A_ be a one-element CharSet containing the character _ch_.
1. Return ! CharacterSetMatcher(_A_, *false*, _direction_).
- The production AtomEscape :: `k` GroupName evaluates as follows:
+ The production AtomEscape ::! `k` GroupName evaluates as follows:
1. Search the enclosing |Pattern| for an instance of a |GroupSpecifier| containing a |RegExpIdentifierName| which has a CapturingGroupName equal to the CapturingGroupName of the |RegExpIdentifierName| contained in |GroupName|.
1. Assert: A unique such |GroupSpecifier| is found.
- 1. Let _parenIndex_ be the number of left-capturing parentheses in the entire regular expression that occur to the left of the located |GroupSpecifier|. This is the total number of Atom :: `(` GroupSpecifier Disjunction `)` Parse Nodes prior to or enclosing the located |GroupSpecifier|, including its immediately enclosing |Atom|.
+ 1. Let _parenIndex_ be the number of left-capturing parentheses in the entire regular expression that occur to the left of the located |GroupSpecifier|. This is the total number of Atom ::! `(` GroupSpecifier Disjunction `)` Parse Nodes prior to or enclosing the located |GroupSpecifier|, including its immediately enclosing |Atom|.
1. Return ! BackreferenceMatcher(_parenIndex_, _direction_).
@@ -31780,7 +31770,7 @@ CharacterClassEscape
CharacterEscape
The |CharacterEscape| productions evaluate as follows:
- CharacterEscape ::
+ CharacterEscape ::!
ControlEscape
`c` ControlLetter
`0` [lookahead <! DecimalDigit]