@@ -171,20 +171,20 @@ compiler knows how to expand them properly:
171
171
` => { $( $( $i)* )* } ` , and ` => { $( $i )+ } ` are all illegal, but
172
172
` => { $( $i );* } ` is correct and replaces a comma-separated list of
173
173
identifiers with a semicolon-separated list.
174
- 1 . Second, each repetition in the transcriber must contain at least one
175
- metavariable to decide how many times to expand it. If multiple
176
- metavariables appear in the same repetition, they must be bound to the same
177
- number of fragments. For instance, `( $( $i: ident ),* ; $( $j: ident ),* ) =>
178
- ( $( ($i,$j) ), * ` must bind the same number of ` $i` fragments as ` $j`
179
- fragments. This means that invoking the macro with ` (a, b, c; d, e, f ` ) is
180
- legal and expands to ` ((a,d), (b,e), (c,f)) ` , but ` (a, b, c; d, e) ` is
181
- illegal because it does not have the same number. This requirement applies
182
- to every layer of nested repetitions.
174
+ 2 . Each repetition in the transcriber must contain at least one metavariable to
175
+ decide how many times to expand it. If multiple metavariables appear in the
176
+ same repetition, they must be bound to the same number of fragments. For
177
+ instance, ` ( $( $i:ident ),* ; $( $j:ident ),* ) =>( $( ($i,$j) ),* ` must
178
+ bind the same number of ` $i ` fragments as ` $j ` fragments. This means that
179
+ invoking the macro with ` (a, b, c; d, e, f ` ) is legal and expands to
180
+ ` ((a,d), (b,e), (c,f)) ` , but ` (a, b, c; d, e) ` is illegal because it does
181
+ not have the same number. This requirement applies to every layer of nested
182
+ repetitions.
183
183
184
184
## Scoping, Exporting, and Importing
185
185
186
- For historical reasons, the scoping of macros by example does not work entirely like
187
- items. Macros have two forms of scope: textual scope, and path-based scope.
186
+ For historical reasons, the scoping of macros by example does not work entirely
187
+ like items. Macros have two forms of scope: textual scope, and path-based scope.
188
188
Textual scope is based on the order that things appear in source files, or even
189
189
across multiple files, and is the default scoping. It is explained further below.
190
190
Path-based scope works exactly the same way that item scoping does. The scoping,
0 commit comments