File tree Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Expand file tree Collapse file tree 3 files changed +4
-6
lines changed Original file line number Diff line number Diff line change 99>   ;  ; [ _ OuterAttribute_ ] <sup >\* </sup > ( _ LifetimeParam_ | _ TypeParam_ | _ ConstParam_ )
1010>
1111> _ LifetimeParam_ :\
12- >   ;  ; [ LIFETIME_OR_LABEL ]   ; ( ` : ` [ _ LifetimeBounds_ ] )<sup >?</sup >
12+ >   ;  ; [ _ Lifetime _ ]   ; ( ` : ` [ _ LifetimeBounds_ ] )<sup >?</sup >
1313>
1414> _ TypeParam_ :\
1515>   ;  ; [ IDENTIFIER]   ; ( ` : ` [ _ TypeParamBounds_ ] <sup >?</sup > )<sup >?</sup > ( ` = ` [ _ Type_ ] )<sup >?</sup >
@@ -44,7 +44,7 @@ See [generic parameter scopes] for more details.
4444[ function pointers] have lifetime or type parameters as well, but are not
4545referred to with path syntax.
4646
47- ` '_ ` is not a valid lifetime parameter .
47+ ` '_ ` and ` '_static ` are not valid lifetime parameters .
4848
4949### Const generics
5050
@@ -263,7 +263,6 @@ struct Foo<#[my_flexible_clone(unbounded)] H> {
263263```
264264
265265[ IDENTIFIER ] : ../identifiers.md
266- [ LIFETIME_OR_LABEL ] : ../tokens.md#lifetimes-and-loop-labels
267266
268267[ _ForLifetimes_ ] : ../trait-bounds.md#higher-ranked-trait-bounds
269268[ _LifetimeParam_ ] : #generic-parameters
Original file line number Diff line number Diff line change @@ -762,8 +762,6 @@ r[lex.token.life.syntax]
762762>
763763> LIFETIME_OR_LABEL :\
764764>   ;  ;   ;  ; ` ' ` [ NON_KEYWORD_IDENTIFIER] [ identifier ]
765- > _ (not immediately followed by ` ' ` )_ \
766- >   ;  ; | ` '_ `
767765> _ (not immediately followed by ` ' ` )_
768766
769767r[ lex.token.life.intro]
Original file line number Diff line number Diff line change @@ -21,7 +21,8 @@ r[bound.syntax]
2121>
2222> _ Lifetime_ :\
2323>   ;  ;   ;  ; [ LIFETIME_OR_LABEL] \
24- >   ;  ; | ` 'static `
24+ >   ;  ; | ` 'static ` \
25+ >   ;  ; | ` '_ `
2526>
2627> _ UseBound_ :\
2728>   ;  ; ` use ` _ UseBoundGenericArgs_
You can’t perform that action at this time.
0 commit comments