Repository: neovim/neovim
File: runtime/lua/vim/lsp/protocol.lua (Lua)

Code before:
  ['implementationProvider'] = { 'textDocument', 'implementation' },
  ['inlayHintProvider'] = { 'textDocument', 'inlayHint' },
  ['inlineCompletionProvider'] = { 'textDocument', 'inlineCompletion' },
  ['inlineValueProvider'] = { 'textDocument', 'inlineValue' },
  ['linkedEditingRangeProvider'] = { 'textDocument', 'linkedEditingRange' },
  ['monikerProvider'] = { 'textDocument', 'moniker' },
  ['documentOnTypeFormattingProvider'] = { 'textDocument', 'onTypeFormatting' },
  ['callHierarchyProvider'] = { 'textDocument', 'callHierarchy' },
  ['typeHierarchyProvider'] = { 'textDocument', 'typeHierarchy' },
  ['documentRangeFormattingProvider'] = { 'textDocument', 'rangeFormatting' },
  ['referencesProvider'] = { 'textDocument', 'references' },
  ['renameProvider'] = { 'textDocument', 'rename' },
  ['selectionRangeProvider'] = { 'textDocument', 'selectionRange' },
  ['semanticTokensProvider'] = { 'textDocument', 'semanticTokens' },
  ['signatureHelpProvider'] = { 'textDocument', 'signatureHelp' },
  ['typeDefinitionProvider'] = { 'textDocument', 'typeDefinition' },
  ['workspace/didChangeConfiguration'] = { 'workspace', 'didChangeConfiguration' },
  ['workspace/didChangeWatchedFiles'] = { 'workspace', 'didChangeWatchedFiles' },
  ['workspace/didCreateFiles'] = { 'workspace', 'fileOperations', 'didCreate' },
  ['workspace/didDeleteFiles'] = { 'workspace', 'fileOperations', 'didDelete' },
  ['workspace/didRenameFiles'] = { 'workspace', 'fileOperations', 'didRename' },
  ['executeCommandProvider'] = { 'workspace', 'executeCommand' },
  ['workspaceSymbolProvider'] = { 'workspace', 'symbol' },
  ['workspace/textDocumentContent'] = { 'workspace', 'textDocumentContent' },
  ['workspace/willCreateFiles'] = { 'workspace', 'fileOperations', 'willCreate' },
  ['workspace/willDeleteFiles'] = { 'workspace', 'fileOperations', 'willDelete' },
  ['workspace/willRenameFiles'] = { 'workspace', 'fileOperations', 'willRename' },
}
-- stylua: ignore end

-- stylua: ignore start
-- Generated by gen_lsp.lua, keep at end of file.
--- Maps method names to the required server capability
protocol._request_name_to_server_capability = {
  ['codeAction/resolve'] = { 'codeActionProvider', 'resolveProvider' },
  ['codeLens/resolve'] = { 'codeLensProvider', 'resolveProvider' },
  ['completionItem/resolve'] = { 'completionProvider', 'resolveProvider' },
  ['documentLink/resolve'] = { 'documentLinkProvider', 'resolveProvider' },
  ['inlayHint/resolve'] = { 'inlayHintProvider', 'resolveProvider' },
  ['textDocument/codeAction'] = { 'codeActionProvider' },
  ['textDocument/codeLens'] = { 'codeLensProvider' },
  ['textDocument/colorPresentation'] = { 'colorProvider' },
  ['textDocument/completion'] = { 'completionProvider' },
  ['textDocument/declaration'] = { 'declarationProvider' },
  ['textDocument/definition'] = { 'definitionProvider' },
  ['textDocument/diagnostic'] = { 'diagnosticProvider' },
  ['textDocument/didChange'] = { 'textDocumentSync' },
  ['textDocument/didClose'] = { 'textDocumentSync', 'openClose' },
  ['textDocument/didOpen'] = { 'textDocumentSync', 'openClose' },
  ['textDocument/didSave'] = { 'textDocumentSync', 'save' },
  ['textDocument/documentColor'] = { 'colorProvider' },

Review comment (suggestion):
It seems the original tracking method was more appropriate? Many method names are left here as keys, yet it is called `provider_to_client_registration.`

Code after:
  ['documentLinkProvider'] = { 'textDocument', 'documentLink' },
  ['documentOnTypeFormattingProvider'] = { 'textDocument', 'onTypeFormatting' },
  ['documentRangeFormattingProvider'] = { 'textDocument', 'rangeFormatting' },
  ['documentSymbolProvider'] = { 'textDocument', 'documentSymbol' },
  ['executeCommandProvider'] = { 'workspace', 'executeCommand' },
  ['foldingRangeProvider'] = { 'textDocument', 'foldingRange' },
  ['hoverProvider'] = { 'textDocument', 'hover' },
  ['implementationProvider'] = { 'textDocument', 'implementation' },
  ['inlayHintProvider'] = { 'textDocument', 'inlayHint' },
  ['inlineCompletionProvider'] = { 'textDocument', 'inlineCompletion' },
  ['inlineValueProvider'] = { 'textDocument', 'inlineValue' },
  ['linkedEditingRangeProvider'] = { 'textDocument', 'linkedEditingRange' },
  ['monikerProvider'] = { 'textDocument', 'moniker' },
  ['referencesProvider'] = { 'textDocument', 'references' },
  ['renameProvider'] = { 'textDocument', 'rename' },
  ['selectionRangeProvider'] = { 'textDocument', 'selectionRange' },
  ['semanticTokensProvider'] = { 'textDocument', 'semanticTokens' },
  ['signatureHelpProvider'] = { 'textDocument', 'signatureHelp' },
  ['textDocumentSync'] = { 'textDocument', 'synchronization' },
  ['typeDefinitionProvider'] = { 'textDocument', 'typeDefinition' },
  ['typeHierarchyProvider'] = { 'textDocument', 'typeHierarchy' },
  ['workspace/didChangeConfiguration'] = { 'workspace', 'didChangeConfiguration' },
  ['workspace/didChangeWatchedFiles'] = { 'workspace', 'didChangeWatchedFiles' },
  ['workspace/didCreateFiles'] = { 'workspace', 'fileOperations', 'didCreate' },
  ['workspace/didDeleteFiles'] = { 'workspace', 'fileOperations', 'didDelete' },
  ['workspace/didRenameFiles'] = { 'workspace', 'fileOperations', 'didRename' },
  ['workspace/textDocumentContent'] = { 'workspace', 'textDocumentContent' },
  ['workspace/willCreateFiles'] = { 'workspace', 'fileOperations', 'willCreate' },
  ['workspace/willDeleteFiles'] = { 'workspace', 'fileOperations', 'willDelete' },
  ['workspace/willRenameFiles'] = { 'workspace', 'fileOperations', 'willRename' },
  ['workspaceSymbolProvider'] = { 'workspace', 'symbol' },
}
-- stylua: ignore end

-- stylua: ignore start
-- Generated by gen_lsp.lua, keep at end of file.
--- Maps method names to the required server capability
protocol._request_name_to_server_capability = {
  ['codeAction/resolve'] = { 'codeActionProvider', 'resolveProvider' },
  ['codeLens/resolve'] = { 'codeLensProvider', 'resolveProvider' },
  ['completionItem/resolve'] = { 'completionProvider', 'resolveProvider' },
  ['documentLink/resolve'] = { 'documentLinkProvider', 'resolveProvider' },
  ['inlayHint/resolve'] = { 'inlayHintProvider', 'resolveProvider' },
  ['textDocument/codeAction'] = { 'codeActionProvider' },
  ['textDocument/codeLens'] = { 'codeLensProvider' },
  ['textDocument/colorPresentation'] = { 'colorProvider' },
  ['textDocument/completion'] = { 'completionProvider' },
  ['textDocument/declaration'] = { 'declarationProvider' },
  ['textDocument/definition'] = { 'definitionProvider' },
  ['textDocument/diagnostic'] = { 'diagnosticProvider' },
  ['textDocument/didChange'] = { 'textDocumentSync' },