summaryrefslogtreecommitdiff
path: root/lib/Frontend/CompilerInvocation.cpp
diff options
context:
space:
mode:
authorBen Langmuir <blangmuir@apple.com>2014-02-05 22:21:15 +0000
committerBen Langmuir <blangmuir@apple.com>2014-02-05 22:21:15 +0000
commite9e34e28c5462932c859aa2c197fecefe37ec647 (patch)
tree7493dca718dd0e341cc78d4dd56f011059dae791 /lib/Frontend/CompilerInvocation.cpp
parentf763bf2808439549b5a42cc60b86c0c0ac880a5b (diff)
downloadclang-e9e34e28c5462932c859aa2c197fecefe37ec647.tar.gz
clang-e9e34e28c5462932c859aa2c197fecefe37ec647.tar.bz2
clang-e9e34e28c5462932c859aa2c197fecefe37ec647.tar.xz
Add a CC1 option -verify-pch
This option will: - load the given pch file - verify it is not out of date by stat'ing dependencies, and - return 0 on success and non-zero on error git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@200884 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Frontend/CompilerInvocation.cpp')
-rw-r--r--lib/Frontend/CompilerInvocation.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/Frontend/CompilerInvocation.cpp b/lib/Frontend/CompilerInvocation.cpp
index 92202b7ee2..da58a0386e 100644
--- a/lib/Frontend/CompilerInvocation.cpp
+++ b/lib/Frontend/CompilerInvocation.cpp
@@ -700,6 +700,8 @@ static InputKind ParseFrontendArgs(FrontendOptions &Opts, ArgList &Args,
Opts.ProgramAction = frontend::ParseSyntaxOnly; break;
case OPT_module_file_info:
Opts.ProgramAction = frontend::ModuleFileInfo; break;
+ case OPT_verify_pch:
+ Opts.ProgramAction = frontend::VerifyPCH; break;
case OPT_print_decl_contexts:
Opts.ProgramAction = frontend::PrintDeclContext; break;
case OPT_print_preamble:
@@ -1585,6 +1587,7 @@ static void ParsePreprocessorOutputArgs(PreprocessorOutputOptions &Opts,
case frontend::GeneratePTH:
case frontend::ParseSyntaxOnly:
case frontend::ModuleFileInfo:
+ case frontend::VerifyPCH:
case frontend::PluginAction:
case frontend::PrintDeclContext:
case frontend::RewriteObjC: