clang API Documentation
#include <PTHManager.h>


Public Types | |
| enum | { Version = 9 } |
Public Member Functions | |
| ~PTHManager () | |
| const char * | getOriginalSourceFile () const |
| IdentifierInfo * | get (StringRef Name) |
| void | setPreprocessor (Preprocessor *pp) |
| PTHLexer * | CreateLexer (FileID FID) |
| FileSystemStatCache * | createStatCache () |
Static Public Member Functions | |
| static PTHManager * | Create (const std::string &file, DiagnosticsEngine &Diags) |
Friends | |
| class | PTHLexer |
Definition at line 36 of file PTHManager.h.
| anonymous enum |
Definition at line 104 of file PTHManager.h.
| PTHManager::~PTHManager | ( | ) |
Definition at line 427 of file PTHLexer.cpp.
| PTHManager * PTHManager::Create | ( | const std::string & | file, |
| DiagnosticsEngine & | Diags | ||
| ) | [static] |
Create - This method creates PTHManager objects. The 'file' argument is the name of the PTH file. This method returns NULL upon failure.
Definition at line 438 of file PTHLexer.cpp.
References clang::OnDiskChainedHashTable< Info >::Create(), InvalidPTH(), clang::io::ReadLE32(), clang::io::ReadUnalignedLE16(), clang::DiagnosticsEngine::Report(), and Version.
Referenced by clang::CompilerInstance::createPreprocessor().
CreateLexer - Return a PTHLexer that "lexes" the cached tokens for the specified file. This method returns NULL if no cached tokens exist. It is the responsibility of the caller to 'delete' the returned object.
Definition at line 590 of file PTHLexer.cpp.
References data(), clang::OnDiskChainedHashTable< Info >::end(), clang::OnDiskChainedHashTable< Info >::find(), clang::SourceManager::getFileEntryForID(), clang::Preprocessor::getSourceManager(), PTHLexer, and clang::io::ReadLE32().
| FileSystemStatCache * PTHManager::createStatCache | ( | ) |
createStatCache - Returns a FileSystemStatCache object for use with FileManager objects. These objects use the PTH data to speed up calls to stat by memoizing their results from when the PTH file was generated.
Definition at line 708 of file PTHLexer.cpp.
| IdentifierInfo * PTHManager::get | ( | StringRef | Name | ) | [virtual] |
get - Return the identifier token info for the specified named identifier. Unlike the version in IdentifierTable, this returns a pointer instead of a reference. If the pointer is NULL then the IdentifierInfo cannot be found.
Implements clang::IdentifierInfoLookup.
Definition at line 576 of file PTHLexer.cpp.
References clang::OnDiskChainedHashTable< Info >::end(), and clang::OnDiskChainedHashTable< Info >::find().
| const char* clang::PTHManager::getOriginalSourceFile | ( | ) | const [inline] |
getOriginalSourceFile - Return the full path to the original header file name that was used to generate the PTH cache.
Definition at line 110 of file PTHManager.h.
Referenced by AddImplicitIncludePTH().
| void clang::PTHManager::setPreprocessor | ( | Preprocessor * | pp | ) | [inline] |
Definition at line 124 of file PTHManager.h.
Referenced by clang::CompilerInstance::createPreprocessor().
friend class PTHLexer [friend] |
Definition at line 37 of file PTHManager.h.
Referenced by CreateLexer().