mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Insert snippet positions after fields names in record patterns
This commit is contained in:
parent
33ecad4407
commit
2cd2947bf8
2 changed files with 6 additions and 6 deletions
|
@ -121,7 +121,7 @@ fn render_record_as_pat(
|
|||
"{name} {{ {}{} }}",
|
||||
fields
|
||||
.enumerate()
|
||||
.map(|(idx, field)| format!("${{{}:{}}}", idx + 1, field.name(db)))
|
||||
.map(|(idx, field)| format!("{}${}", field.name(db), idx + 1))
|
||||
.format(", "),
|
||||
if fields_omitted { ", .." } else { "" },
|
||||
name = name
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue