clang-tools 20.0.0git
|
Maps a definition location onto an #include file, based on a set of filename rules. More...
#include <CanonicalIncludes.h>
Public Member Functions | |
llvm::StringRef | mapHeader (llvm::StringRef HeaderPath) const |
Returns the overridden verbatim spelling for files in Header that can be directly included (i.e., contains quotes "" or angled brackets <>), or "" if the spelling could not be found. | |
void | addSystemHeadersMapping (const LangOptions &Language) |
Adds mapping for system headers and some special symbols (e.g. | |
Maps a definition location onto an #include file, based on a set of filename rules.
Only const methods (i.e. mapHeader) in this class are thread safe.
Definition at line 33 of file CanonicalIncludes.h.
void clang::clangd::CanonicalIncludes::addSystemHeadersMapping | ( | const LangOptions & | Language | ) |
Adds mapping for system headers and some special symbols (e.g.
STL symbols in <iosfwd> need to be mapped individually). Approximately, the following system headers are handled:
Definition at line 709 of file CanonicalIncludes.cpp.
Referenced by clang::clangd::SymbolCollector::HeaderFileURICache::mapCanonical().
llvm::StringRef clang::clangd::CanonicalIncludes::mapHeader | ( | llvm::StringRef | HeaderPath | ) | const |
Returns the overridden verbatim spelling for files in Header
that can be directly included (i.e., contains quotes "" or angled brackets <>), or "" if the spelling could not be found.
Definition at line 691 of file CanonicalIncludes.cpp.
References clang::clangd::MaxSuffixComponents.
Referenced by clang::clangd::SymbolCollector::HeaderFileURICache::mapCanonical().