aboutsummaryrefslogtreecommitdiff
path: root/crates/ide_completion/src/completions/unqualified_path.rs
diff options
context:
space:
mode:
Diffstat (limited to 'crates/ide_completion/src/completions/unqualified_path.rs')
-rw-r--r--crates/ide_completion/src/completions/unqualified_path.rs10
1 files changed, 3 insertions, 7 deletions
diff --git a/crates/ide_completion/src/completions/unqualified_path.rs b/crates/ide_completion/src/completions/unqualified_path.rs
index 7875500c1..046a393ae 100644
--- a/crates/ide_completion/src/completions/unqualified_path.rs
+++ b/crates/ide_completion/src/completions/unqualified_path.rs
@@ -9,11 +9,7 @@ pub(crate) fn complete_unqualified_path(acc: &mut Completions, ctx: &CompletionC
9 if !ctx.is_trivial_path { 9 if !ctx.is_trivial_path {
10 return; 10 return;
11 } 11 }
12 if ctx.record_lit_syntax.is_some() 12 if ctx.is_path_disallowed() {
13 || ctx.record_pat_syntax.is_some()
14 || ctx.attribute_under_caret.is_some()
15 || ctx.mod_declaration_under_caret.is_some()
16 {
17 return; 13 return;
18 } 14 }
19 15
@@ -86,7 +82,7 @@ fn quux(x: Option<Enum>) {
86 } 82 }
87} 83}
88"#, 84"#,
89 expect![[""]], 85 expect![[r#""#]],
90 ); 86 );
91 } 87 }
92 88
@@ -102,7 +98,7 @@ fn quux(x: Option<Enum>) {
102 } 98 }
103} 99}
104"#, 100"#,
105 expect![[""]], 101 expect![[r#""#]],
106 ); 102 );
107 } 103 }
108 104