mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 06:11:35 +00:00
Finalize TypeBound grammar
This commit is contained in:
parent
a6527ed92c
commit
b250ae6c55
4 changed files with 35 additions and 54 deletions
|
@ -242,6 +242,13 @@ ImplTraitType =
|
|||
DynTraitType =
|
||||
'dyn' TypeBoundList
|
||||
|
||||
TypeBoundList =
|
||||
bounds:(TypeBound ('+' TypeBound)* '+'?)
|
||||
|
||||
TypeBound =
|
||||
'lifetime'
|
||||
| '?'? Type
|
||||
|
||||
TupleExpr =
|
||||
Attr* '(' Expr* ')'
|
||||
|
||||
|
@ -443,12 +450,6 @@ MacroStmts =
|
|||
statements:Stmt*
|
||||
Expr?
|
||||
|
||||
TypeBound =
|
||||
'lifetime' | 'const'? Type
|
||||
|
||||
TypeBoundList =
|
||||
bounds:TypeBound*
|
||||
|
||||
WherePred =
|
||||
('for' GenericParamList)? ('lifetime' | Type) ':' TypeBoundList
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue