aboutsummaryrefslogtreecommitdiffstats
path: root/lsp/rust_analyzer.lua
diff options
context:
space:
mode:
authorSteve Walker <65963536+stevalkr@users.noreply.github.com>2025-04-27 18:15:32 +0800
committerGitHub <noreply@github.com>2025-04-27 18:15:32 +0800
commit48f4475eb71638b69c984557169dc3826603d37e (patch)
tree5ff86f25fb89b8c7d866bd0d4c92d2176847897c /lsp/rust_analyzer.lua
parentdocs: update configs.md (diff)
downloadnvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar.gz
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar.bz2
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar.lz
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar.xz
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.tar.zst
nvim-lspconfig-48f4475eb71638b69c984557169dc3826603d37e.zip
fix(rust_analyzer): scheduled vim.notify in on_exit of vim.system(#3793)
Fix `E5560: nvim_echo must not be called in a fast event context`
Diffstat (limited to 'lsp/rust_analyzer.lua')
-rw-r--r--lsp/rust_analyzer.lua4
1 files changed, 3 insertions, 1 deletions
diff --git a/lsp/rust_analyzer.lua b/lsp/rust_analyzer.lua
index ba71bba4..0540aca2 100644
--- a/lsp/rust_analyzer.lua
+++ b/lsp/rust_analyzer.lua
@@ -96,7 +96,9 @@ return {
on_dir(cargo_workspace_root or cargo_crate_dir)
else
- vim.notify(('[rust_analyzer] cmd failed with code %d: %s\n%s'):format(output.code, cmd, output.stderr))
+ vim.schedule(function()
+ vim.notify(('[rust_analyzer] cmd failed with code %d: %s\n%s'):format(output.code, cmd, output.stderr))
+ end)
end
end)
end,