diff options
Diffstat (limited to 'crates/completion/src/context.rs')
-rw-r--r-- | crates/completion/src/context.rs | 13 |
1 files changed, 0 insertions, 13 deletions
diff --git a/crates/completion/src/context.rs b/crates/completion/src/context.rs index dca304a8f..bf70ee478 100644 --- a/crates/completion/src/context.rs +++ b/crates/completion/src/context.rs | |||
@@ -245,19 +245,6 @@ impl<'a> CompletionContext<'a> { | |||
245 | } | 245 | } |
246 | } | 246 | } |
247 | 247 | ||
248 | pub(crate) fn active_name_and_type(&self) -> Option<(String, Type)> { | ||
249 | if let Some(record_field) = &self.record_field_syntax { | ||
250 | mark::hit!(record_field_type_match); | ||
251 | let (struct_field, _local) = self.sema.resolve_record_field(record_field)?; | ||
252 | Some((struct_field.name(self.db).to_string(), struct_field.signature_ty(self.db))) | ||
253 | } else if let Some(active_parameter) = &self.active_parameter { | ||
254 | mark::hit!(active_param_type_match); | ||
255 | Some((active_parameter.name.clone(), active_parameter.ty.clone())) | ||
256 | } else { | ||
257 | None | ||
258 | } | ||
259 | } | ||
260 | |||
261 | fn fill_keyword_patterns(&mut self, file_with_fake_ident: &SyntaxNode, offset: TextSize) { | 248 | fn fill_keyword_patterns(&mut self, file_with_fake_ident: &SyntaxNode, offset: TextSize) { |
262 | let fake_ident_token = file_with_fake_ident.token_at_offset(offset).right_biased().unwrap(); | 249 | let fake_ident_token = file_with_fake_ident.token_at_offset(offset).right_biased().unwrap(); |
263 | let syntax_element = NodeOrToken::Token(fake_ident_token); | 250 | let syntax_element = NodeOrToken::Token(fake_ident_token); |