feat(lsp): support textDocument/foldingRange (#31311)

* refactor(shared): extract `vim._list_insert` and `vim._list_remove`

* feat(lsp): add `vim.lsp.foldexpr()`

* docs(lsp): add a todo for state management

* feat(lsp): add `vim.lsp.folding_range.foldclose()`

* feat(lsp): schedule `foldclose()` if the buffer is not up-to-date

* feat(lsp): add `vim.lsp.foldtext()`

* feat(lsp): support multiple folding range providers

* refactor(lsp): expose all folding related functions under `vim.lsp.*`

* perf(lsp): add `lsp.MultiHandler` for do `foldupdate()` only once
This commit is contained in:
Yi Ming
2024-11-29 20:40:32 +08:00
committed by GitHub
parent c867a4f5e3
commit a1e313ded6
9 changed files with 1141 additions and 49 deletions

View File

@ -274,6 +274,7 @@ local config = {
'diagnostic.lua',
'codelens.lua',
'completion.lua',
'folding_range.lua',
'inlay_hint.lua',
'tagfunc.lua',
'semantic_tokens.lua',