mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-10-01 06:11:35 +00:00
Cleanup PathCompletionContext qualifier handling
This commit is contained in:
parent
a3ad99649f
commit
33fd2d7aef
10 changed files with 89 additions and 91 deletions
|
@ -19,7 +19,7 @@ use ide_db::{
|
|||
use syntax::{SmolStr, SyntaxKind, TextRange};
|
||||
|
||||
use crate::{
|
||||
context::{PathCompletionContext, PathKind},
|
||||
context::{PathCompletionCtx, PathKind},
|
||||
item::{CompletionRelevanceTypeMatch, ImportEdit},
|
||||
render::{enum_variant::render_variant, function::render_fn, macro_::render_macro},
|
||||
CompletionContext, CompletionItem, CompletionItemKind, CompletionRelevance,
|
||||
|
@ -234,7 +234,7 @@ fn render_resolution_(
|
|||
// Add `<>` for generic types
|
||||
let type_path_no_ty_args = matches!(
|
||||
ctx.completion.path_context,
|
||||
Some(PathCompletionContext { kind: Some(PathKind::Type), has_type_args: false, .. })
|
||||
Some(PathCompletionCtx { kind: Some(PathKind::Type), has_type_args: false, .. })
|
||||
) && ctx.completion.config.add_call_parenthesis;
|
||||
if type_path_no_ty_args {
|
||||
if let Some(cap) = ctx.snippet_cap() {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue