sammccall added a comment.

Thanks for cleaning this up!



================
Comment at: clangd/ClangdLSPServer.cpp:433
 
     reparseOpenedFiles();
   }
----------------
This isn't needed, the compilation database can only be set during 
initialization.


================
Comment at: clangd/ClangdLSPServer.h:90
   void reparseOpenedFiles();
+  void applyConfiguration(const ClangdInitializationOptions &Settings);
   void applyConfiguration(const ClangdConfigurationParamsChange &Settings);
----------------
Prefer a different name for this function - an overload set should have similar 
semantics and these are quite different (pseudo-constructor vs mutation allowed 
at any time).


================
Comment at: clangd/Protocol.h:422
+struct ClangdInitializationOptions : public ClangdConfigurationParamsChange {
+  llvm::Optional<std::string> compilationDatabasePath;
+};
----------------
Can we just move this to InitializeParams as a clangd extension?
Doing tricks with inheritance here makes the protocol harder to understand.


Repository:
  rCTE Clang Tools Extra

https://reviews.llvm.org/D53220



_______________________________________________
cfe-commits mailing list
cfe-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to