In "Fill match arms", allow users to prefer Self to the enum name when possible

But default to not to.

I chose to have a more generic config name because maybe other assists could also use the same approach.
This commit is contained in:
Chayim Refael Friedman 2025-06-06 16:34:53 +03:00
parent 4fd1cdb3e3
commit 25a7b2480e
7 changed files with 227 additions and 29 deletions

View file

@ -680,6 +680,16 @@
}
}
},
{
"title": "assist",
"properties": {
"rust-analyzer.assist.preferSelf": {
"markdownDescription": "When inserting a type (e.g. in \"fill match arms\" assist), prefer to use `Self` over the type name where possible.",
"default": false,
"type": "boolean"
}
}
},
{
"title": "assist",
"properties": {