diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2013-03-08 20:42:38 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2013-03-08 20:42:38 +0000 |
commit | f8f373f47210b88bdf71acb5579b129b665235ab (patch) | |
tree | e79c024082862cdd9c0aaa2374fcb3187039afce | |
parent | 389dc5603fa10b508a38f668a7830c6d877b6542 (diff) |
[PCH] When complaining that a header from the PCH was modified, also mention
the filename of the PCH file.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@176717 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | include/clang/Basic/DiagnosticSerializationKinds.td | 2 | ||||
-rw-r--r-- | lib/Serialization/ASTReader.cpp | 2 | ||||
-rw-r--r-- | test/PCH/modified-header-error.c | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/include/clang/Basic/DiagnosticSerializationKinds.td b/include/clang/Basic/DiagnosticSerializationKinds.td index 6e377cc035..bc5bd4e2ad 100644 --- a/include/clang/Basic/DiagnosticSerializationKinds.td +++ b/include/clang/Basic/DiagnosticSerializationKinds.td @@ -18,7 +18,7 @@ def err_fe_pch_malformed : Error< def err_fe_pch_malformed_block : Error< "malformed block record in PCH file: '%0'">, DefaultFatal; def err_fe_pch_file_modified : Error< - "file '%0' has been modified since the precompiled header was built">, + "file '%0' has been modified since the precompiled header '%1' was built">, DefaultFatal; def err_fe_pch_file_overridden : Error< "file '%0' from the precompiled header has been overridden">; diff --git a/lib/Serialization/ASTReader.cpp b/lib/Serialization/ASTReader.cpp index 4ad51e5dea..743204e316 100644 --- a/lib/Serialization/ASTReader.cpp +++ b/lib/Serialization/ASTReader.cpp @@ -1602,7 +1602,7 @@ InputFile ASTReader::getInputFile(ModuleFile &F, unsigned ID, bool Complain) { #endif )) { if (Complain) - Error(diag::err_fe_pch_file_modified, Filename); + Error(diag::err_fe_pch_file_modified, Filename, F.FileName); IsOutOfDate = true; } diff --git a/test/PCH/modified-header-error.c b/test/PCH/modified-header-error.c index ef9249447a..4ad3fafff4 100644 --- a/test/PCH/modified-header-error.c +++ b/test/PCH/modified-header-error.c @@ -8,5 +8,5 @@ #include "header2.h" -// CHECK: fatal error: file {{.*}} has been modified since the precompiled header was built +// CHECK: fatal error: file {{.*}} has been modified since the precompiled header {{.*}} was built // REQUIRES: shell |