aboutsummaryrefslogtreecommitdiff
path: root/lib/Serialization
diff options
context:
space:
mode:
authorKaelyn Uhrain <rikka@google.com>2012-06-20 00:36:03 +0000
committerKaelyn Uhrain <rikka@google.com>2012-06-20 00:36:03 +0000
commitda01f62cdfb0995db355c61d96d45b0f1d790b3d (patch)
treec402506a6974a2bef624f39fbad0a5fa69c14e5d /lib/Serialization
parentaa0cd85838f2a024e589ea4e8c2094130065af21 (diff)
Add the PCH file name to the message about not being able to read the PCH.
Also add a couple of unit tests to check the invalid-PCH error messages to satisfy PR4568 and for the assertion (introduced in r149918 and fixed in r158769) that would cause clang to crash when given an empty PCH. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@158772 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Serialization')
-rw-r--r--lib/Serialization/ASTReader.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/Serialization/ASTReader.cpp b/lib/Serialization/ASTReader.cpp
index f5aa74ea98..da031575a2 100644
--- a/lib/Serialization/ASTReader.cpp
+++ b/lib/Serialization/ASTReader.cpp
@@ -3001,7 +3001,7 @@ std::string ASTReader::getOriginalSourceFile(const std::string &ASTFileName,
OwningPtr<llvm::MemoryBuffer> Buffer;
Buffer.reset(FileMgr.getBufferForFile(ASTFileName, &ErrStr));
if (!Buffer) {
- Diags.Report(diag::err_fe_unable_to_read_pch_file) << ErrStr;
+ Diags.Report(diag::err_fe_unable_to_read_pch_file) << ASTFileName << ErrStr;
return std::string();
}