summaryrefslogtreecommitdiffstats
path: root/clang/lib/Lex/PTHLexer.cpp
diff options
context:
space:
mode:
authorDouglas Gregor <dgregor@apple.com>2009-10-16 18:18:30 +0000
committerDouglas Gregor <dgregor@apple.com>2009-10-16 18:18:30 +0000
commitd2eb58abac2d25b188628e825eab75077eb7aac8 (patch)
tree55f7b6d575dc540e4eee6f3e36972885ea89db9d /clang/lib/Lex/PTHLexer.cpp
parentd0099a94dbf2e2a14b654d8c333a03b9c8ec8fca (diff)
downloadbcm5719-llvm-d2eb58abac2d25b188628e825eab75077eb7aac8.tar.gz
bcm5719-llvm-d2eb58abac2d25b188628e825eab75077eb7aac8.zip
Add support for a chain of stat caches in the FileManager, rather than
only supporting a single stat cache. The immediate benefit of this change is that we can now generate a PCH/AST file when including another PCH file; in the future, the chain of stat caches will likely be useful with multiple levels of PCH files. llvm-svn: 84263
Diffstat (limited to 'clang/lib/Lex/PTHLexer.cpp')
-rw-r--r--clang/lib/Lex/PTHLexer.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Lex/PTHLexer.cpp b/clang/lib/Lex/PTHLexer.cpp
index 36ace8be7e0..f804f82c489 100644
--- a/clang/lib/Lex/PTHLexer.cpp
+++ b/clang/lib/Lex/PTHLexer.cpp
@@ -679,7 +679,8 @@ public:
CacheTy::iterator I = Cache.find(path);
// If we don't get a hit in the PTH file just forward to 'stat'.
- if (I == Cache.end()) return ::stat(path, buf);
+ if (I == Cache.end())
+ return StatSysCallCache::stat(path, buf);
const PTHStatData& Data = *I;
OpenPOWER on IntegriCloud