You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
RepeatRangeInclusive -> `{` ( Name `:` )? Range? `..=` Range `}`
72
69
73
-
RepeatRangeInclusive -> `{` Range? `..=` Range `}`
70
+
RepeatRangeNamed -> `{` Name `}`
74
71
75
72
Range -> [0-9]+
76
73
@@ -145,11 +142,11 @@ The general format is a series of productions separated by blank lines. The expr
145
142
| Optional | Expr? | The preceding expression is optional. |
146
143
| NegativeLookahead | !Expr | Matches if Expr does not follow, without consuming any input. |
147
144
| Repeat | Expr*| The preceding expression is repeated 0 or more times. |
148
-
| RepeatNonGreedy | Expr*? | The preceding expression is repeated 0 or more times without being greedy. |
149
145
| RepeatPlus | Expr+ | The preceding expression is repeated 1 or more times. |
150
-
| RepeatPlusNonGreedy | Expr+? | The preceding expression is repeated 1 or more times without being greedy. |
151
146
| RepeatRange | Expr{2..4} | The preceding expression is repeated between the range of times specified. Either bound can be excluded, which works just like Rust ranges. |
152
147
| RepeatRangeInclusive | Expr{2..=4} | The preceding expression is repeated between the inclusive range of times specified. The lower bound can be omitted. |
148
+
| RepeatRange (named) | Expr{name:2..4} | When a name precedes the range, the number of repetitions is bound to that name so that subsequent RepeatRangeNamed expressions can refer to it. The same applies to RepeatRangeInclusive. |
149
+
| RepeatRangeNamed | Expr{name} | The preceding expression is repeated the number of times determined by a previously named RepeatRange or RepeatRangeInclusive. |
0 commit comments