diff options
author | Aleksey Kladov <[email protected]> | 2020-04-11 22:33:17 +0100 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2020-04-11 23:00:15 +0100 |
commit | 5e5eb6a108b00c573455d8d088742592012707be (patch) | |
tree | 49146b7e25835f21c09f75ec56e129367f56cab0 /crates/ra_ide/src/completion/complete_pattern.rs | |
parent | 6b49e774e23c04a04ff5f377fc8dae25b5c69bb0 (diff) |
Align grammar for record patterns and literals
The grammar now looks like this
[name_ref :] pat
Diffstat (limited to 'crates/ra_ide/src/completion/complete_pattern.rs')
-rw-r--r-- | crates/ra_ide/src/completion/complete_pattern.rs | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/crates/ra_ide/src/completion/complete_pattern.rs b/crates/ra_ide/src/completion/complete_pattern.rs index 1b7d3122f..a8b4ce114 100644 --- a/crates/ra_ide/src/completion/complete_pattern.rs +++ b/crates/ra_ide/src/completion/complete_pattern.rs | |||
@@ -7,6 +7,10 @@ pub(super) fn complete_pattern(acc: &mut Completions, ctx: &CompletionContext) { | |||
7 | if !ctx.is_pat_binding_or_const { | 7 | if !ctx.is_pat_binding_or_const { |
8 | return; | 8 | return; |
9 | } | 9 | } |
10 | if ctx.record_pat_syntax.is_some() { | ||
11 | return; | ||
12 | } | ||
13 | |||
10 | // FIXME: ideally, we should look at the type we are matching against and | 14 | // FIXME: ideally, we should look at the type we are matching against and |
11 | // suggest variants + auto-imports | 15 | // suggest variants + auto-imports |
12 | ctx.scope().process_all_names(&mut |name, res| { | 16 | ctx.scope().process_all_names(&mut |name, res| { |