From afdb56990212eb385e77fff9a6316a16e50bd1d4 Mon Sep 17 00:00:00 2001 From: DJMcNab <36049421+DJMcNab@users.noreply.github.com> Date: Thu, 10 Jan 2019 18:21:01 +0000 Subject: Fix handling of where clauses in tuple structs --- crates/ra_syntax/src/grammar/items/nominal.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'crates/ra_syntax/src/grammar') diff --git a/crates/ra_syntax/src/grammar/items/nominal.rs b/crates/ra_syntax/src/grammar/items/nominal.rs index 8d02ad555..495462ca7 100644 --- a/crates/ra_syntax/src/grammar/items/nominal.rs +++ b/crates/ra_syntax/src/grammar/items/nominal.rs @@ -29,6 +29,10 @@ pub(super) fn struct_def(p: &mut Parser, kind: SyntaxKind) { L_CURLY => named_field_def_list(p), L_PAREN if kind == STRUCT_KW => { pos_field_list(p); + // test tuple_struct_where + // struct Test(T) where T: Clone; + // struct Test(T); + type_params::opt_where_clause(p); p.expect(SEMI); } _ if kind == STRUCT_KW => { -- cgit v1.2.3