[PATCH] D60687: [clangd] Check file path of declaring header when deciding whether to insert include.
Sam McCall via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Tue Apr 16 02:09:22 PDT 2019
sammccall added inline comments.
================
Comment at: unittests/clangd/HeadersTests.cpp:208
TEST_F(HeadersTest, DoNotInsertIfInSameFile) {
MainFile = testPath("main.h");
----------------
ioeric wrote:
> > IIUC, this already fixes the cases we'd seen of include-insertion of a header into itself.
> > Is it feasible to add a test case for that?
> Here is a test case for it. However, to trigger the old behavior caused by include spelling, we would need to implement a custom URI scheme that performs include spelling customization. Let me know if you think we should add one.
>
Ah right, this probably isn't worth it :-(
Repository:
rCTE Clang Tools Extra
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D60687/new/
https://reviews.llvm.org/D60687
More information about the cfe-commits
mailing list