[PATCH] D105177: [clangd] Implemented indexing of standard library

Nathan Ridge via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Aug 17 12:34:58 PDT 2021


nridge added inline comments.


================
Comment at: clang-tools-extra/clangd/index/StdLib.cpp:72
+  Inputs.TFS = &TFS;
+  // TODO: can we get a real compile command from somewhere?
+  Inputs.CompileCommand.Directory = virtualRoot().str();
----------------
sammccall wrote:
> I'm not sure what this means, I don't think there's anything better to do here.
One could imagine picking a source file from the project's CDB, and using its flags to parse the standard library.

That could be relevant for macros that affect the way standard library headers are parsed (like `_GLIBCXX_DEBUG` perhaps?)


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D105177



More information about the cfe-commits mailing list