Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/syntax/rust.ungram')
-rw-r--r--crates/syntax/rust.ungram10
1 files changed, 4 insertions, 6 deletions
diff --git a/crates/syntax/rust.ungram b/crates/syntax/rust.ungram
index 08c8749e36..4c9027dec6 100644
--- a/crates/syntax/rust.ungram
+++ b/crates/syntax/rust.ungram
@@ -46,13 +46,14 @@ GenericArg =
| AssocTypeArg
| LifetimeArg
| ConstArg
-| ReturnTypeArg
TypeArg =
Type
AssocTypeArg =
- NameRef GenericArgList? (':' TypeBoundList | ('=' Type | ConstArg))
+ NameRef
+ (GenericArgList | ParamList RetType?)?
+ (':' TypeBoundList | ('=' Type | ConstArg))
LifetimeArg =
Lifetime
@@ -60,9 +61,6 @@ LifetimeArg =
ConstArg =
Expr
-ReturnTypeArg =
- NameRef '(' '..' ')' ':' TypeBoundList
-
MacroCall =
Attr* Path '!' TokenTree ';'?
@@ -585,7 +583,7 @@ ImplTraitType =
'impl' TypeBoundList
DynTraitType =
- 'dyn' TypeBoundList
+ 'dyn'? TypeBoundList
TypeBoundList =
bounds:(TypeBound ('+' TypeBound)* '+'?)