🔧 chore(lsp_server): keep full provider/capability list commented
This commit is contained in:
parent
d13b24a5da
commit
1a784c6452
|
|
@ -82,6 +82,51 @@ namespace lsp::provider
|
|||
// NOTE: Only advertise the minimal feature set for now:
|
||||
// - completion (with resolve)
|
||||
// - go-to-definition
|
||||
//
|
||||
// Staged rollout: keep other capabilities disabled. Uncomment as features are re-enabled.
|
||||
// result.capabilities.typeDefinitionProvider = true;
|
||||
// result.capabilities.implementationProvider = true;
|
||||
// result.capabilities.hoverProvider = true;
|
||||
// result.capabilities.signatureHelpProvider = BuildSignatureHelpOptions();
|
||||
// result.capabilities.codeActionProvider = BuildCodeActionOptions();
|
||||
// result.capabilities.codeLensProvider = protocol::CodeLensOptions{ .resolveProvider = true };
|
||||
// result.capabilities.documentLinkProvider = protocol::DocumentLinkOptions{ .resolveProvider = true };
|
||||
// result.capabilities.colorProvider = true;
|
||||
// result.capabilities.referencesProvider = true;
|
||||
// result.capabilities.documentHighlightProvider = true;
|
||||
// result.capabilities.renameProvider = protocol::RenameOptions{ .prepareProvider = true };
|
||||
// result.capabilities.documentSymbolProvider = true;
|
||||
// result.capabilities.workspaceSymbolProvider = protocol::WorkspaceSymbolOptions{ .resolveProvider = true };
|
||||
// result.capabilities.semanticTokensProvider = BuildSemanticTokenOptions();
|
||||
// result.capabilities.callHierarchyProvider = true;
|
||||
// result.capabilities.typeHierarchyProvider = true;
|
||||
// result.capabilities.inlayHintProvider = protocol::InlayHintOptions{ .resolveProvider = true };
|
||||
// result.capabilities.foldingRangeProvider = true;
|
||||
// result.capabilities.selectionRangeProvider = true;
|
||||
// result.capabilities.linkedEditingRangeProvider = true;
|
||||
// result.capabilities.monikerProvider = true;
|
||||
// result.capabilities.inlineValueProvider = true;
|
||||
// result.capabilities.documentFormattingProvider = true;
|
||||
// result.capabilities.documentRangeFormattingProvider = true;
|
||||
// result.capabilities.documentOnTypeFormattingProvider = BuildOnTypeFormattingOptions();
|
||||
// result.capabilities.executeCommandProvider = BuildExecuteCommandOptions();
|
||||
//
|
||||
// protocol::DiagnosticOptions diagnostic;
|
||||
// diagnostic.identifier = "syntax";
|
||||
// diagnostic.interFileDependencies = false;
|
||||
// diagnostic.workspaceDiagnostics = true;
|
||||
// result.capabilities.diagnosticProvider = std::move(diagnostic);
|
||||
//
|
||||
// protocol::ServerCapabilities::Workspace workspace;
|
||||
// protocol::ServerCapabilities::Workspace::FileOperations file_operations;
|
||||
// file_operations.didCreate = true;
|
||||
// file_operations.willCreate = true;
|
||||
// file_operations.didDelete = true;
|
||||
// file_operations.willDelete = true;
|
||||
// file_operations.didRename = true;
|
||||
// file_operations.willRename = true;
|
||||
// workspace.fileOperations = std::move(file_operations);
|
||||
// result.capabilities.workspace = std::move(workspace);
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -103,6 +103,89 @@ export namespace lsp::provider
|
|||
SetTrace
|
||||
>;
|
||||
|
||||
// Full provider registry (kept commented for quick re-enable during staged rollout):
|
||||
// using AllProviders = ProviderRegistry<
|
||||
// call_hierarchy::IncomingCalls,
|
||||
// call_hierarchy::OutgoingCalls,
|
||||
// CancelRequest,
|
||||
// client::RegisterCapability,
|
||||
// client::UnregisterCapability,
|
||||
// code_action::Resolve,
|
||||
// code_lens::Resolve,
|
||||
// completion_item::Resolve,
|
||||
// document_link::Resolve,
|
||||
// Exit,
|
||||
// Initialize,
|
||||
// Initialized,
|
||||
// inlay_hint::Resolve,
|
||||
// Shutdown,
|
||||
// telemetry::Event,
|
||||
// text_document::CodeAction,
|
||||
// text_document::CodeLens,
|
||||
// text_document::ColorPresentation,
|
||||
// text_document::Completion,
|
||||
// text_document::Definition,
|
||||
// text_document::Diagnostic,
|
||||
// text_document::DidChange,
|
||||
// text_document::DidClose,
|
||||
// text_document::DidOpen,
|
||||
// text_document::DocumentColor,
|
||||
// text_document::DocumentHighlight,
|
||||
// text_document::DocumentLink,
|
||||
// text_document::DocumentSymbol,
|
||||
// text_document::FoldingRange,
|
||||
// text_document::Formatting,
|
||||
// text_document::Hover,
|
||||
// text_document::Implementation,
|
||||
// text_document::InlayHint,
|
||||
// text_document::InlineValue,
|
||||
// text_document::LinkedEditingRange,
|
||||
// text_document::Moniker,
|
||||
// text_document::OnTypeFormatting,
|
||||
// text_document::PrepareCallHierarchy,
|
||||
// text_document::PrepareRename,
|
||||
// text_document::PrepareTypeHierarchy,
|
||||
// text_document::PublishDiagnostics,
|
||||
// text_document::RangeFormatting,
|
||||
// text_document::References,
|
||||
// text_document::Rename,
|
||||
// text_document::SelectionRange,
|
||||
// text_document::SemanticTokensRange,
|
||||
// text_document::SemanticTokensFull,
|
||||
// text_document::SemanticTokensFullDelta,
|
||||
// text_document::SignatureHelp,
|
||||
// text_document::TypeDefinition,
|
||||
// SetTrace,
|
||||
// type_hierarchy::Subtypes,
|
||||
// type_hierarchy::Supertypes,
|
||||
// window::LogMessage,
|
||||
// window::ShowDocument,
|
||||
// window::ShowMessage,
|
||||
// window::ShowMessageRequest,
|
||||
// window::WorkDoneProgressCreate,
|
||||
// workspace::ApplyEdit,
|
||||
// workspace::CodeLensRefresh,
|
||||
// workspace::Configuration,
|
||||
// workspace::Diagnostic,
|
||||
// workspace::DidChangeConfiguration,
|
||||
// workspace::DidChangeWatchedFiles,
|
||||
// workspace::DidChangeWorkspaceFolders,
|
||||
// workspace::DidCreateFiles,
|
||||
// workspace::DidDeleteFiles,
|
||||
// workspace::DidRenameFiles,
|
||||
// workspace::DiagnosticRefresh,
|
||||
// workspace::ExecuteCommand,
|
||||
// workspace::InlayHintRefresh,
|
||||
// workspace::InlineValueRefresh,
|
||||
// workspace::SemanticTokensRefresh,
|
||||
// workspace::Symbol,
|
||||
// workspace::WorkspaceFolders,
|
||||
// workspace::WillCreateFiles,
|
||||
// workspace::WillDeleteFiles,
|
||||
// workspace::WillRenameFiles,
|
||||
// workspace_symbol::Resolve
|
||||
// >;
|
||||
|
||||
static_assert(AllProviders::kProviderCount > 0, "No providers registered.");
|
||||
|
||||
inline void RegisterAllProviders(core::RequestDispatcher& dispatcher)
|
||||
|
|
|
|||
Loading…
Reference in New Issue