aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2012-08-24 23:42:58 +0000
committerTed Kremenek <kremenek@apple.com>2012-08-24 23:42:58 +0000
commit0d3a3fd7211a1b368d1f8c0d7ca1cfd40d31a0ea (patch)
tree3139c0ce82325a2d49b20e46af5da22b6f67e8b4
parent810e6229e59796f8109e94e4a469a2dc17cf3e6d (diff)
Fix a few issues related to -with-analyzer reported by Jordan. Let's
have the option with two '--' to be consistent with other options. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162625 91177308-0d34-0410-b5e6-96231b3b80d8
-rwxr-xr-xtools/scan-build/scan-build10
1 files changed, 5 insertions, 5 deletions
diff --git a/tools/scan-build/scan-build b/tools/scan-build/scan-build
index 12dd653e11..d62ef0323e 100755
--- a/tools/scan-build/scan-build
+++ b/tools/scan-build/scan-build
@@ -1080,8 +1080,8 @@ ADVANCED OPTIONS:
Generate internal analyzer statistics.
- -with-analyzer [Xcode|path to clang]
- -with-analyzer=[Xcode|path to clang]
+ --with-analyzer [Xcode|path to clang]
+ --with-analyzer=[Xcode|path to clang]
scan-build uses the 'clang' executable relative to itself for static
analysis. One can override this behavior with this option by using the
@@ -1435,12 +1435,12 @@ while (@ARGV) {
push @PluginsToLoad, "-load", shift @ARGV;
next;
}
- if ($arg eq "-with-analyzer") {
+ if ($arg eq "--with-analyzer") {
shift @ARGV;
$AnalyzerDiscoveryMethod = shift @ARGV;
next;
}
- if ($arg =~ /^-with-analyzer=(.+)$/) {
+ if ($arg =~ /^--with-analyzer=(.+)$/) {
shift @ARGV;
$AnalyzerDiscoveryMethod = $1;
next;
@@ -1473,7 +1473,7 @@ if (!defined $AnalyzerDiscoveryMethod) {
}
}
else {
- if ($AnalyzerDiscoveryMethod =~ /^[X,x]code$/) {
+ if ($AnalyzerDiscoveryMethod =~ /^[Xx]code$/) {
my $xcrun = `which xcrun`;
chomp $xcrun;
if ($xcrun eq "") {