From c3589753a0e191843836fe08ff425d79b3354ccf Mon Sep 17 00:00:00 2001 From: Maria Solano Date: Wed, 18 Feb 2026 18:16:03 -0800 Subject: [PATCH] fix(lsp): add `vim.deprecate` call to `vim.lsp.with` (#37960) --- runtime/lua/vim/lsp.lua | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/runtime/lua/vim/lsp.lua b/runtime/lua/vim/lsp.lua index 08592aa0f1..2cadfc4247 100644 --- a/runtime/lua/vim/lsp.lua +++ b/runtime/lua/vim/lsp.lua @@ -1570,6 +1570,11 @@ end ---@param handler (lsp.Handler) See |lsp-handler| ---@param override_config (table) Table containing the keys to override behavior of the {handler} function lsp.with(handler, override_config) + vim.deprecate( + 'vim.lsp.with()', + 'Pass the configuration to equivalent functions in `vim.lsp.buf`', + '0.12' + ) return function(err, result, ctx, config) return handler(err, result, ctx, vim.tbl_deep_extend('force', config or {}, override_config)) end