kadircet marked 3 inline comments as done.
kadircet added a comment.

It seems like the most relevant place in tooling is ArgumentsAdjuster as 
@ioeric pointed out. Happy to move it to there if @sammccall and @klimek agrees 
as well.

As a side note `ArgumentsAdjuster`s unfortunately causes a copy of the original 
command line arguments. Not sure how important this factor is compared to 
spinning up a compiler instance, just wanted to point it out.



================
Comment at: clangd/ClangdUnit.cpp:433
+    // <arbitrary-argument>
+    if (I + 4 < E && CommandLine[I] == "-Xclang" &&
+        (CommandLine[I + 1] == "-load" || CommandLine[I + 1] == "-plugin" ||
----------------
ilya-biryukov wrote:
> Maybe move this code into `ClangdServer::getCompileCommand` to keep **all** 
> argument adjustments that we do in clangd in one place.
> We add `-resource-dir` there.
As mentioned in the change description, we also have a different compiler 
invocation in `BackgroundIndex` which is not aware of 
`ClangdServer::getCompileCommand`


Repository:
  rCTE Clang Tools Extra

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D56841/new/

https://reviews.llvm.org/D56841



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

Reply via email to