♻️ 重构
This commit is contained in:
@@ -14,10 +14,9 @@ namespace lsp::provider::client
|
||||
return "ClientRegisterCapability";
|
||||
}
|
||||
|
||||
std::string RegisterCapability::ProvideResponse(const protocol::RequestMessage& request, ExecutionContext& context)
|
||||
std::string RegisterCapability::ProvideResponse(const protocol::RequestMessage& request, [[maybe_unused]] ExecutionContext& context)
|
||||
{
|
||||
static_cast<void>(context);
|
||||
spdlog::debug("RegisterCapabilityProvider: Providing response for method {}", request.method);
|
||||
spdlog::debug("RegisterCapabilityProvider: Providing response for method {}", request.method);
|
||||
// 这个方法通常不会被调用,因为这是服务器发起的请求
|
||||
// 但为了完整性还是实现它
|
||||
|
||||
|
||||
@@ -14,10 +14,9 @@ namespace lsp::provider::client
|
||||
return "ClientUnregisterCapability";
|
||||
}
|
||||
|
||||
std::string UnregisterCapability::ProvideResponse(const protocol::RequestMessage& request, ExecutionContext& context)
|
||||
std::string UnregisterCapability::ProvideResponse(const protocol::RequestMessage& request, [[maybe_unused]] ExecutionContext& context)
|
||||
{
|
||||
static_cast<void>(context);
|
||||
spdlog::debug("UnregisterCapabilityProvider: Providing response for method {}", request.method);
|
||||
spdlog::debug("UnregisterCapabilityProvider: Providing response for method {}", request.method);
|
||||
protocol::ResponseMessage response;
|
||||
response.id = request.id;
|
||||
response.result = std::nullopt;
|
||||
|
||||
Reference in New Issue
Block a user