[PATCH] D95270: [clangd][NFC] Simplify handing on methods with no params
Nathan James via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Jan 25 03:41:01 PST 2021
njames93 added inline comments.
================
Comment at: clang-tools-extra/clangd/ClangdLSPServer.cpp:262
+ template <typename Result>
+ void bind(const char *Method,
+ void (ClangdLSPServer::*Handler)(const NoParams &,
----------------
kadircet wrote:
> why do we need this one ?
Good point, this one is never actually used now.
================
Comment at: clang-tools-extra/clangd/ClangdLSPServer.h:93
void onInitialize(const InitializeParams &, Callback<llvm::json::Value>);
void onInitialized(const InitializedParams &);
+ void onShutdown(Callback<std::nullptr_t>);
----------------
kadircet wrote:
> any reasons for keeping `InitializedParams` ?
Although its empty, its defined in the protocol so we should be mirroring it.
================
Comment at: clang-tools-extra/clangd/Protocol.h:267
}
using InitializedParams = NoParams;
----------------
kadircet wrote:
> and drop this too.
See previous comment about mirroring the spec.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D95270/new/
https://reviews.llvm.org/D95270
More information about the cfe-commits
mailing list