mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
add space before/after wrapping braces
This commit is contained in:
parent
68d3743faf
commit
e88eb89132
1 changed files with 2 additions and 2 deletions
|
@ -280,7 +280,7 @@ impl Completions {
|
||||||
StructKind::Record => {
|
StructKind::Record => {
|
||||||
join(detail_types.map(|(n, t)| format!("{}: {}", n, t.display(ctx.db).to_string())))
|
join(detail_types.map(|(n, t)| format!("{}: {}", n, t.display(ctx.db).to_string())))
|
||||||
.separator(", ")
|
.separator(", ")
|
||||||
.surround_with("{", "}")
|
.surround_with("{ ", " }")
|
||||||
.to_string()
|
.to_string()
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -328,7 +328,7 @@ mod tests {
|
||||||
delete: [121; 123),
|
delete: [121; 123),
|
||||||
insert: "Foo",
|
insert: "Foo",
|
||||||
kind: EnumVariant,
|
kind: EnumVariant,
|
||||||
detail: "{x: i32, y: i32}",
|
detail: "{ x: i32, y: i32 }",
|
||||||
},
|
},
|
||||||
]"###
|
]"###
|
||||||
);
|
);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue