Changelog #19
source link: https://rust-analyzer.github.io/thisweek/2020/04/06/changelog-19.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
New Features
-
BREAKING
#3824
changed the name of many options. The current set is specified here . If you are using a non-VS Code client, note that rust-analyzer now asks forrust-analyzer
secion of configuration, and expects this config to be present ininitializationOptions
. -
#3804
,#3825
it is now possible to use arbitrary command for on the fly error checking:{ "rust-analyzer.checkOnSave.overrideCommand": [ "./x.py", "check", "--json-output" ] }
-
#3807
,#3825
similarly, it is now possible to completely overriderustfmt
command. -
#3820
remove support for old syntax highlighting. To use the new semantic tokens highlighting:-
install the recent vscode insiders build
-
add
{ "rust-analyzer.highlighting.semanticTokens": true, "editor.semanticHighlighting.enabled": false, }
to config
-
run vscode as
code-insiders --enabled-proposed-api matklad.rust-analyzer
-
make sure to use a color theme with support for syntax highlighitng.
-
Rust specific tokens and modifiers are listed here . For example, to underline all
mut
and&mut
variables, add this tosettings.json
:"editor.tokenColorCustomizationsExperimental": { "*.mutable": { "fontStyle": "underline" } }
-
-
#3814
add Implement From for enum variant assist -
#3746
add Create function assist. -
#3840
automatically add call parenthesis for tuple-like enum variants -
#3666
handle some configuration changes without server restart. -
#3777
populate default task list in VS Code with cargo commands. -
#3765
SSR no longer takes field order into account. -
#3829
SSR treats method call and UFCS equivalently. -
#3779
code completion for recrod literals now suggest only fields which are not already present.
Recommend
About Joyk
Aggregate valuable and interesting links.
Joyk means Joy of geeK