[PATCH] D55275: [clangd] Dont provide locations for non-existent files.

Haojian Wu via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Wed Dec 5 00:05:04 PST 2018


hokein added inline comments.


================
Comment at: unittests/clangd/SymbolCollectorTests.cpp:1036
+  runSymbolCollector(Header, /*Main=*/"", {"-Dfoo=bar"});
+  EXPECT_THAT(Symbols, UnorderedElementsAre(QName("bar")));
+}
----------------
We handled this case previously, but the code was removed in rL346488 (looks like sam missed the case where we don't use preamble, like building static index). I think we should bring the logic back -- revert the change of `isSpelledInSourceCode` and add `SymbolCollectorTest, SymbolFormedByCLI` should be enough.


Repository:
  rCTE Clang Tools Extra

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

https://reviews.llvm.org/D55275





More information about the cfe-commits mailing list