aboutsummaryrefslogtreecommitdiffstats
path: root/lua/lspconfig/util.lua
diff options
context:
space:
mode:
authorJohn Drouhard <john@jmdtech.org>2021-01-08 16:11:34 -0600
committerJohn Drouhard <john@jmdtech.org>2021-01-08 16:12:36 -0600
commit53ef07e5158e3f347db1be9ea5090466434b37b7 (patch)
tree296a0b80c73af46602ba6b52dd5478c76fa5c635 /lua/lspconfig/util.lua
parentMerge pull request #560 from mjlbach/readme_tweaks (diff)
downloadnvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar.gz
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar.bz2
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar.lz
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar.xz
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.tar.zst
nvim-lspconfig-53ef07e5158e3f347db1be9ea5090466434b37b7.zip
clangd: fix capabilities by extending protocol defaults with utf-8 offset encoding
Also removes the utf8_config helper function which was only used by clangd and is a clangd-specific protocol extension.
Diffstat (limited to 'lua/lspconfig/util.lua')
-rw-r--r--lua/lspconfig/util.lua10
1 files changed, 0 insertions, 10 deletions
diff --git a/lua/lspconfig/util.lua b/lua/lspconfig/util.lua
index d218b25d..5b45ff51 100644
--- a/lua/lspconfig/util.lua
+++ b/lua/lspconfig/util.lua
@@ -326,16 +326,6 @@ function M.find_package_json_ancestor(startpath)
end)
end
-function M.utf8_config(config)
- config.capabilities = config.capabilities or lsp.protocol.make_client_capabilities()
- config.capabilities.offsetEncoding = {"utf-8", "utf-16"}
- function config.on_init(client, result)
- if result.offsetEncoding then
- client.offset_encoding = result.offsetEncoding
- end
- end
- return config
-end
return M
-- vim:et ts=2 sw=2