[PATCH] D142836: [clangd] Add symbol mappings for `std::experimental::filesystem`
Younan Zhang via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Sun Jan 29 01:56:01 PST 2023
zyounan created this revision.
Herald added subscribers: kadircet, arphaman.
Herald added a project: All.
zyounan edited the summary of this revision.
zyounan added reviewers: hokein, sammccall, nridge.
zyounan published this revision for review.
Herald added subscribers: cfe-commits, MaskRay, ilya-biryukov.
Herald added projects: clang, clang-tools-extra.
Clangd maintains a symbol map from standard library, in order to prevent
unexpected header/symbol leaks from internal files. (e.g. files under
`bits/` for libstdc++) This symbol map was generated by a python script
that parses pages of offline cppreference archive. The script didn't
handle the case for `std::experimental::`, where most symbols are from
TS. It works well as symbols are directly laid out in the corresponding
header under `experimental` directory for most of time.
However, libstdc++'s implementation split symbols of TS FS into a few
header files located in `experimental/bits`. This would make the code
completion provide internal headers when we simply select the symbols.
This fixes https://github.com/clangd/clangd/issues/1481
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D142836
Files:
clang-tools-extra/clangd/index/CanonicalIncludes.cpp
clang-tools-extra/clangd/unittests/CanonicalIncludesTests.cpp
clang/include/clang/Tooling/Inclusions/TsStdSymbolMap.inc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D142836.493078.patch
Type: text/x-patch
Size: 6978 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20230129/bda23470/attachment-0001.bin>
More information about the cfe-commits
mailing list