This patch moves the GlobalCompilationDatabase and FileSystemProvider
dependencies of ClangdLSPServer to ClangdMain and makes ClangdLSPServer itself a DiagnosticsConsumer.
Details
- Reviewers
ilya-biryukov
Diff Detail
- Build Status
Buildable 7245 Build 7245: arc lint + arc unit
Event Timeline
clangd/ClangdLSPServer.h | ||
---|---|---|
26 | I would not expect ClangdLSPServer to be passed as a DiagnosticsConsumer. | |
29 | What are the use-cases for getting GlobalCompilationDatabase and FileSystemProvider as an outside parameter? I.e. the purpose of this class is to provide an easy interface to just run LSP server without worrying about its configuration. |
I would not expect ClangdLSPServer to be passed as a DiagnosticsConsumer.
It's not the purpose of this class at all, therefore I don't think it's a good idea to inherit publicly from DiagnosticsConsumer.
Private inheritance would be fine (to reduce code repetition), but is generally considered to be hard-to-grasp.