File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ Valid fragment specifiers are:
134
134
* ` block ` : a [ BlockExpression]
135
135
* ` expr ` : an [ Expression]
136
136
* ` expr_2021 ` : an [ Expression] except [ UnderscoreExpression] and [ ConstBlockExpression] (see [ macro.decl.meta.edition2024] )
137
- * ` ident ` : an [ IDENTIFIER_OR_KEYWORD] or [ RAW_IDENTIFIER]
137
+ * ` ident ` : an [ IDENTIFIER_OR_KEYWORD] , [ RAW_IDENTIFIER] , or ` $crate `
138
138
* ` item ` : an [ Item]
139
139
* ` lifetime ` : a [ LIFETIME_TOKEN]
140
140
* ` literal ` : matches ` - ` <sup >?</sup >[ LiteralExpression]
Original file line number Diff line number Diff line change @@ -350,8 +350,9 @@ r[macro.proc.token.conversion.to-proc_macro]
350
350
When passed to a proc-macro
351
351
- All multi-character operators are broken into single characters.
352
352
- Lifetimes are broken into a ` ' ` character and an identifier.
353
- - All metavariable substitutions are represented as their underlying token
354
- streams.
353
+ - The keyword metavariable ` $crate ` is passed as a single identifier.
354
+ - All other metavariable substitutions are represented as their underlying
355
+ token streams.
355
356
- Such token streams may be wrapped into delimited groups ([ ` Group ` ] ) with
356
357
implicit delimiters ([ ` Delimiter::None ` ] ) when it's necessary for
357
358
preserving parsing priorities.
You can’t perform that action at this time.
0 commit comments