aboutsummaryrefslogtreecommitdiff
path: root/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
diff options
context:
space:
mode:
authorGabor Horvath <xazax.hun@gmail.com>2016-08-08 13:41:04 +0000
committerGabor Horvath <xazax.hun@gmail.com>2016-08-08 13:41:04 +0000
commitc430990d0bd4b32312049adbf6a84afc990813eb (patch)
treed08d8cbd7f216ca7361682c9e5498e73f1414377 /clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
parent142f4f76be8b9c65385029213a36248e34547e3f (diff)
downloadllvm-c430990d0bd4b32312049adbf6a84afc990813eb.zip
llvm-c430990d0bd4b32312049adbf6a84afc990813eb.tar.gz
llvm-c430990d0bd4b32312049adbf6a84afc990813eb.tar.bz2
[analyzer] Command line option to show enabled checker list.
This patch adds a command line option to list the checkers that were enabled by analyzer-checker and not disabled by -analyzer-disable-checker. It can be very useful to debug long command lines when it is not immediately apparent which checkers are turned on and which checkers are turned off. Differential Revision: https://reviews.llvm.org/D23060 llvm-svn: 278006
Diffstat (limited to 'clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp')
-rw-r--r--clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp b/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
index 509c326..13cb52a 100644
--- a/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
+++ b/clang/lib/FrontendTool/ExecuteCompilerInvocation.cpp
@@ -229,6 +229,11 @@ bool clang::ExecuteCompilerInvocation(CompilerInstance *Clang) {
ento::printCheckerHelp(llvm::outs(), Clang->getFrontendOpts().Plugins);
return true;
}
+ if (Clang->getAnalyzerOpts()->ShowEnabledCheckerList) {
+ ento::printEnabledCheckerList(llvm::outs(),
+ Clang->getFrontendOpts().Plugins,
+ *Clang->getAnalyzerOpts());
+ }
#endif
// If there were errors in processing arguments, don't do anything else.