Open IWANABETHATGUY opened 1 year ago
related code in rust-analyzer vscode extension https://github.com/rust-lang/rust-analyzer/blob/master/editors/code/src/lsp_ext.ts#L45-L47
Looks pretty cool, do you need to disable checkOnSave
when you want to use this?
In theory, yes. Because if you enable checkOnSave
, save will trigger a fly check already. This is only useful when cargo check
cost pretty long time.
I've pulled this in https://github.com/MunifTanjim/rust-tools.nvim/tree/patched
In theory, yes. Because if you enable
checkOnSave
, save will trigger a fly check already. This is only useful whencargo check
cost pretty long time.
So basically you only need to make sure you have this checkOnSave turned off to benefit from that feature. Might be worth adding a note about it in the doc so that people knows about it
cargo check
after each save is pretty costly, especially when the project became very large.rust analyzer
will on demand trigger cargo check and push the diagnostics into neovim lsp client