[PATCH] D49523: [clangd] Add support for per-file override compilation command

Alex Lorenz via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Jul 20 14:13:00 PDT 2018


arphaman added a comment.

In https://reviews.llvm.org/D49523#1169621, @jkorous wrote:

> Alex, I am just wondering if we shouldn't rather create another implementation of GlobalCompilationDatabase interface (something like InMemoryGlobalCompilationDatabase), add it to ClangdServer and use it as the first place to be searched in ClangdServer::getCompileCommand(PathRef File). What do you think?


We can certainly create another class, but I'd be against adding it into `ClangdServer`. It makes sense to have just one CDB in there. If we had our own server instead of ClangdLSP then this class would be really useful, but for now this solution is probably preferable.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D49523





More information about the cfe-commits mailing list