File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -76,9 +76,9 @@ should only be used to parse text; if you wish to extract complex data, an
76
76
L < action object|/language/grammars#Action_Objects > is recommended to be used in
77
77
conjunction with the grammar.
78
78
79
- X < sym >
80
- X << :sym<> >>
81
- X < protoregex >
79
+ X < | sym>
80
+ X << | :sym<> >>
81
+ X < | protoregex>
82
82
= head2 Protoregexes
83
83
84
84
If you have a lot of alternations, it may become difficult to produce
@@ -161,7 +161,7 @@ the thing works—all thanks to protoregexes.
161
161
162
162
= head2 Special Tokens
163
163
164
- X < TOP >
164
+ X < | TOP>
165
165
= head3 C < TOP >
166
166
167
167
grammar Foo {
@@ -179,7 +179,7 @@ Using C<rule TOP> or C<regex TOP> are also acceptable.
179
179
A different token can be chosen to be matched first using the C < :rule > named
180
180
argument to C < .parse > , C < .subparse > , or C < .parsefile > C < Grammar > methods.
181
181
182
- X < ws >
182
+ X < | ws>
183
183
= head3 C < ws >
184
184
185
185
When C < rule > instead of C < token > is used, any whitespace after an
@@ -206,7 +206,7 @@ It's perfectly fine to provide your own C<ws> token:
206
206
}.parse: "4 \n\n 5"; # Fails
207
207
208
208
209
- X << <?> >>
209
+ X << | <?> >>
210
210
= head3 Always Succeed Assertion
211
211
212
212
The C << <?> >> is the I < always succeed > assertion. When used as a grammar
You can’t perform that action at this time.
0 commit comments