[PATCH] D54872: [clangd] Add ability to not use -resource-dir at all

Ilya Biryukov via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 5 05:13:44 PST 2018


ilya-biryukov added a comment.

In D54872#1319684 <https://reviews.llvm.org/D54872#1319684>, @malaperle wrote:

> It doesn't seem like there is any difference in how -resource-dir and /imsvc are handled: they are all added as -internal-isystem


Thanks for digging this code up.
I'm a bit confused now, will put up a few clarifying questions to make sure I understand the probem properly.
Does `clang-cl` work correctly the arguments from `compile_commands.json`? Does it fail if we add the `-resource-dir`, similar to how it was done for clangd? The `compile-commands.json` seems to be generated for the MSVC  or hand-crafted, I wonder if it may be a difference between the clang frontend and msvc (unlikely, but just to be sure).
The `compile_commands.json` does not even mention the `-resource-dir`, I wonder why would adding it break anything? The only thing that comes to mind is some of the microsoft headers being named the same as the clang headers, but having more stuff in them (the `uintptr_t` that's missing). Is that the case?


Repository:
  rCTE Clang Tools Extra

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

https://reviews.llvm.org/D54872





More information about the cfe-commits mailing list