summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend/CacheTokens.cpp
diff options
context:
space:
mode:
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>2011-03-05 01:03:53 +0000
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>2011-03-05 01:03:53 +0000
commit11e6f0a6c30e4352f8146f9d7e3c9439c67f3f3d (patch)
treeb715b9189c297184a94e31b3663fc97944ec39d1 /clang/lib/Frontend/CacheTokens.cpp
parent4954bc1d9d68bfbe6d39cf2c6d7a5d9944e31a73 (diff)
downloadbcm5719-llvm-11e6f0a6c30e4352f8146f9d7e3c9439c67f3f3d.tar.gz
bcm5719-llvm-11e6f0a6c30e4352f8146f9d7e3c9439c67f3f3d.zip
Currently we can only remap a file by creating a MemoryBuffer and replacing the file contents with it.
Allow remapping a file by specifying another filename whose contents should be loaded if the original file gets loaded. This allows to override files without having to create & load buffers in advance. llvm-svn: 127052
Diffstat (limited to 'clang/lib/Frontend/CacheTokens.cpp')
-rw-r--r--clang/lib/Frontend/CacheTokens.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Frontend/CacheTokens.cpp b/clang/lib/Frontend/CacheTokens.cpp
index 50182247fc7..06a1fd29838 100644
--- a/clang/lib/Frontend/CacheTokens.cpp
+++ b/clang/lib/Frontend/CacheTokens.cpp
@@ -473,7 +473,7 @@ void PTHWriter::GeneratePTH(const std::string &MainFile) {
for (SourceManager::fileinfo_iterator I = SM.fileinfo_begin(),
E = SM.fileinfo_end(); I != E; ++I) {
const SrcMgr::ContentCache &C = *I->second;
- const FileEntry *FE = C.Entry;
+ const FileEntry *FE = C.OrigEntry;
// FIXME: Handle files with non-absolute paths.
if (llvm::sys::path::is_relative(FE->getName()))
OpenPOWER on IntegriCloud