Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'crates/parser/src/grammar/items.rs')
-rw-r--r--crates/parser/src/grammar/items.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/crates/parser/src/grammar/items.rs b/crates/parser/src/grammar/items.rs
index 36d13cc977..7bfd9ef8c8 100644
--- a/crates/parser/src/grammar/items.rs
+++ b/crates/parser/src/grammar/items.rs
@@ -290,12 +290,17 @@ fn type_alias(p: &mut Parser, m: Marker) {
generic_params::bounds(p);
}
- // test type_item_where_clause
+ // test type_item_where_clause_deprecated
// type Foo where Foo: Copy = ();
generic_params::opt_where_clause(p);
if p.eat(T![=]) {
types::type_(p);
}
+
+ // test type_item_where_clause
+ // type Foo = () where Foo: Copy;
+ generic_params::opt_where_clause(p);
+
p.expect(T![;]);
m.complete(p, TYPE_ALIAS);
}