A refactoring to decouple ProtocolHandlers and Language Server input parsing
loop from the ClangdLSPServer.
The input parsing was extracted from main to a function(runLanguageServerLoop).
ProtocolHandlers now provide an interface to handle various LSP methods,
this interface is used by ClangdLSPServer.
Methods for code formatting were moved from ProtocolHandlers to ClangdServer.
ClangdLSPServer now provides a cleaner interface that only runs Language Server
input loop.
Details
Diff Detail
- Build Status
Buildable 6470 Build 6470: arc lint + arc unit
Event Timeline
| clangd/ClangdLSPServer.cpp | ||
|---|---|---|
| 20 | Hm, this is a bit too generic for my taste. Is it ever used generically? | |
| clangd/ClangdLSPServer.cpp | ||
|---|---|---|
| 20 | Nope, it's now only used with one type, specialized it to it. | |
| clangd/ClangdLSPServer.h | ||
| 33 | Didn't want to store unnecessary fields in the class, but we do need JSONOutput &Out as a member, since there's consumeDiagnostics which uses it. | |
It seems strange to have the In here and the Out in the constructor.