mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
internal: fix naming polarity
Type Constructors have *parameters*, when they are substituted with type *arguments*, we have a type.
This commit is contained in:
parent
cb3ef552e8
commit
1a01a5ae19
4 changed files with 6 additions and 6 deletions
|
@ -304,11 +304,11 @@ fn module_def_doctest(sema: &Semantics<RootDatabase>, def: hir::ModuleDef) -> Op
|
|||
let name = adt.name(sema.db);
|
||||
let idx = path.rfind(':').map_or(0, |idx| idx + 1);
|
||||
let (prefix, suffix) = path.split_at(idx);
|
||||
let mut ty_params = ty.type_parameters().peekable();
|
||||
let params = if ty_params.peek().is_some() {
|
||||
let mut ty_args = ty.type_arguments().peekable();
|
||||
let params = if ty_args.peek().is_some() {
|
||||
format!(
|
||||
"<{}>",
|
||||
ty_params.format_with(", ", |ty, cb| cb(&ty.display(sema.db)))
|
||||
ty_args.format_with(", ", |ty, cb| cb(&ty.display(sema.db)))
|
||||
)
|
||||
} else {
|
||||
String::new()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue