diff options
| author | Chayim Refael Friedman <chayimfr@gmail.com> | 2025-06-06 16:34:53 +0300 |
|---|---|---|
| committer | Chayim Refael Friedman <chayimfr@gmail.com> | 2025-06-06 16:34:53 +0300 |
| commit | 2a473e5aa6c8869dfef3891e32c77085338e4f46 (patch) | |
| tree | 68fbc8c23303bafdb74b69e1af1d15db55a8a4d9 /src/tools/rust-analyzer/editors/code | |
| parent | 337c2d993b00cf727be28e6e1435fbbca17c9f2a (diff) | |
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.
Diffstat (limited to 'src/tools/rust-analyzer/editors/code')
| -rw-r--r-- | src/tools/rust-analyzer/editors/code/package.json | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/tools/rust-analyzer/editors/code/package.json b/src/tools/rust-analyzer/editors/code/package.json index c8c36cd85c8..398d0c51e9a 100644 --- a/src/tools/rust-analyzer/editors/code/package.json +++ b/src/tools/rust-analyzer/editors/code/package.json @@ -683,6 +683,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": { "rust-analyzer.assist.termSearch.borrowcheck": { "markdownDescription": "Enable borrow checking for term search code assists. If set to false, also there will be more suggestions, but some of them may not borrow-check.", "default": true, |
