diff options
author | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:02:28 +0000 |
---|---|---|
committer | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:02:28 +0000 |
commit | 7442d6faa2719e4e7d33a7021c406c5a4facd74d (patch) | |
tree | c72b9241553fc9966179aba84f90f17bfa9235c3 /test/Analysis/diagnostics | |
parent | b52119637f743680a99710ce5fdb6646da2772af (diff) |
Notes
Diffstat (limited to 'test/Analysis/diagnostics')
16 files changed, 29 insertions, 28 deletions
diff --git a/test/Analysis/diagnostics/deref-track-symbolic-region.c b/test/Analysis/diagnostics/deref-track-symbolic-region.c index 42060ccd9260f..179e736ee18bb 100644 --- a/test/Analysis/diagnostics/deref-track-symbolic-region.c +++ b/test/Analysis/diagnostics/deref-track-symbolic-region.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist // RUN: FileCheck --input-file=%t.plist %s struct S { diff --git a/test/Analysis/diagnostics/deref-track-symbolic-region.cpp b/test/Analysis/diagnostics/deref-track-symbolic-region.cpp index 6d348415aaf3d..61993f0872f40 100644 --- a/test/Analysis/diagnostics/deref-track-symbolic-region.cpp +++ b/test/Analysis/diagnostics/deref-track-symbolic-region.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=text -verify %s struct S { int *x; diff --git a/test/Analysis/diagnostics/diag-cross-file-boundaries.c b/test/Analysis/diagnostics/diag-cross-file-boundaries.c index 270163e85607b..b975af3fb29fa 100644 --- a/test/Analysis/diagnostics/diag-cross-file-boundaries.c +++ b/test/Analysis/diagnostics/diag-cross-file-boundaries.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=html -o PR12421.html %s 2>&1 | FileCheck %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=html -o PR12421.html %s 2>&1 | FileCheck %s // Test for PR12421 #include "diag-cross-file-boundaries.h" diff --git a/test/Analysis/diagnostics/explicit-suppression.cpp b/test/Analysis/diagnostics/explicit-suppression.cpp index d36def20f25fd..193846c082bcc 100644 --- a/test/Analysis/diagnostics/explicit-suppression.cpp +++ b/test/Analysis/diagnostics/explicit-suppression.cpp @@ -1,5 +1,6 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config suppress-c++-stdlib=false -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core,debug.ExprInspection -analyzer-config suppress-c++-stdlib=true -DSUPPRESSED=1 -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config suppress-c++-stdlib=false -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config suppress-c++-stdlib=true -DSUPPRESSED=1 -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -DSUPPRESSED=1 -verify %s #ifdef SUPPRESSED // expected-no-diagnostics diff --git a/test/Analysis/diagnostics/false-positive-suppression.c b/test/Analysis/diagnostics/false-positive-suppression.c index cdcd7cc777980..87c04cbcdc074 100644 --- a/test/Analysis/diagnostics/false-positive-suppression.c +++ b/test/Analysis/diagnostics/false-positive-suppression.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -I %S/Inputs -analyze -analyzer-checker=core,unix -verify %s +// RUN: %clang_analyze_cc1 -I %S/Inputs -analyzer-checker=core,unix -verify %s // expected-no-diagnostics #include "include/sys/queue.h" diff --git a/test/Analysis/diagnostics/implicit-cxx-std-suppression.cpp b/test/Analysis/diagnostics/implicit-cxx-std-suppression.cpp index 143cbbeeac204..197fad5d0b7de 100644 --- a/test/Analysis/diagnostics/implicit-cxx-std-suppression.cpp +++ b/test/Analysis/diagnostics/implicit-cxx-std-suppression.cpp @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,cplusplus.NewDelete,debug.ExprInspection -analyzer-config c++-container-inlining=true -analyzer-config c++-stdlib-inlining=false -std=c++11 -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix.Malloc,cplusplus.NewDelete,debug.ExprInspection -analyzer-config c++-container-inlining=true -analyzer-config c++-stdlib-inlining=true -std=c++11 -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,unix.Malloc,cplusplus.NewDelete,debug.ExprInspection -analyzer-config c++-container-inlining=true -analyzer-config c++-stdlib-inlining=false -std=c++11 -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,unix.Malloc,cplusplus.NewDelete,debug.ExprInspection -analyzer-config c++-container-inlining=true -analyzer-config c++-stdlib-inlining=true -std=c++11 -verify %s // expected-no-diagnostics diff --git a/test/Analysis/diagnostics/macros.cpp b/test/Analysis/diagnostics/macros.cpp index 8d7fccde1c618..5aa2c03ab0ed1 100644 --- a/test/Analysis/diagnostics/macros.cpp +++ b/test/Analysis/diagnostics/macros.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -std=c++11 -analyzer-checker=core,osx -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -std=c++11 -analyzer-checker=core,osx -analyzer-output=text -verify %s #include "../Inputs/system-header-simulator.h" #include "../Inputs/system-header-simulator-cxx.h" diff --git a/test/Analysis/diagnostics/macros.m b/test/Analysis/diagnostics/macros.m index 7ef80b302dd93..b459974862148 100644 --- a/test/Analysis/diagnostics/macros.m +++ b/test/Analysis/diagnostics/macros.m @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -fblocks -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,osx -fblocks -analyzer-output=text -verify %s #include "../Inputs/system-header-simulator-objc.h" diff --git a/test/Analysis/diagnostics/no-prune-paths.c b/test/Analysis/diagnostics/no-prune-paths.c index fab5cf82059be..6e9e45766bf5a 100644 --- a/test/Analysis/diagnostics/no-prune-paths.c +++ b/test/Analysis/diagnostics/no-prune-paths.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -analyzer-config prune-paths=false -DNPRUNE=1 -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=text -analyzer-config prune-paths=false -DNPRUNE=1 -verify %s // "prune-paths" is a debug option only; this is just a simple test to see that // it's being honored. diff --git a/test/Analysis/diagnostics/plist-diagnostics-include-check.cpp b/test/Analysis/diagnostics/plist-diagnostics-include-check.cpp index 6ed39451a8bc3..8c66b96007ebc 100644 --- a/test/Analysis/diagnostics/plist-diagnostics-include-check.cpp +++ b/test/Analysis/diagnostics/plist-diagnostics-include-check.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=debug.ExprInspection -analyzer-output=plist-multi-file %s -o %t.plist +// RUN: %clang_analyze_cc1 -analyzer-checker=debug.ExprInspection -analyzer-output=plist-multi-file %s -o %t.plist // RUN: FileCheck --input-file=%t.plist %s #include "Inputs/include/plist-diagnostics-include-check-macro.h" diff --git a/test/Analysis/diagnostics/report-issues-within-main-file.cpp b/test/Analysis/diagnostics/report-issues-within-main-file.cpp index 5fd7abd03c4a2..784fdba972df3 100644 --- a/test/Analysis/diagnostics/report-issues-within-main-file.cpp +++ b/test/Analysis/diagnostics/report-issues-within-main-file.cpp @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,unix -analyzer-output=plist-multi-file -analyzer-config report-in-main-source-file=true -analyzer-config path-diagnostics-alternate=false %s -o %t.plist +// RUN: %clang_analyze_cc1 -analyzer-checker=core,unix -analyzer-output=plist-multi-file -analyzer-config report-in-main-source-file=true -analyzer-config path-diagnostics-alternate=false %s -o %t.plist // RUN: FileCheck --input-file=%t.plist %s #include "Inputs/include/report-issues-within-main-file.h" diff --git a/test/Analysis/diagnostics/shortest-path-suppression.c b/test/Analysis/diagnostics/shortest-path-suppression.c index 4f648b986b25a..d0fa4b51ef448 100644 --- a/test/Analysis/diagnostics/shortest-path-suppression.c +++ b/test/Analysis/diagnostics/shortest-path-suppression.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-config suppress-null-return-paths=true -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-config suppress-null-return-paths=true -analyzer-output=text -verify %s // expected-no-diagnostics int *returnNull() { return 0; } diff --git a/test/Analysis/diagnostics/text-diagnostics.c b/test/Analysis/diagnostics/text-diagnostics.c index 592521672ff40..01946476e099f 100644 --- a/test/Analysis/diagnostics/text-diagnostics.c +++ b/test/Analysis/diagnostics/text-diagnostics.c @@ -1,4 +1,4 @@ -// RUN: %clang --analyze -Xanalyzer -analyzer-output=text -fno-caret-diagnostics %s 2>&1 | FileCheck %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core.NullDereference -analyzer-output=text -fno-caret-diagnostics %s 2>&1 | FileCheck %s void testA() { int *p = 0; diff --git a/test/Analysis/diagnostics/undef-value-caller.c b/test/Analysis/diagnostics/undef-value-caller.c index dc19e0a2b856c..4f273bd9a72d4 100644 --- a/test/Analysis/diagnostics/undef-value-caller.c +++ b/test/Analysis/diagnostics/undef-value-caller.c @@ -1,4 +1,4 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=plist -analyzer-config path-diagnostics-alternate=false -o %t %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=plist -analyzer-config path-diagnostics-alternate=false -o %t %s // RUN: FileCheck --input-file %t %s #include "undef-value-callee.h" diff --git a/test/Analysis/diagnostics/undef-value-param.c b/test/Analysis/diagnostics/undef-value-param.c index 8ebf0daf2b49e..837b0419ef20d 100644 --- a/test/Analysis/diagnostics/undef-value-param.c +++ b/test/Analysis/diagnostics/undef-value-param.c @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=text -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist // RUN: FileCheck --input-file=%t.plist %s void foo_irrelevant(int c) { diff --git a/test/Analysis/diagnostics/undef-value-param.m b/test/Analysis/diagnostics/undef-value-param.m index b9947d8ce019e..f8212e0b9df31 100644 --- a/test/Analysis/diagnostics/undef-value-param.m +++ b/test/Analysis/diagnostics/undef-value-param.m @@ -1,5 +1,5 @@ -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -analyzer-output=text -verify %s -// RUN: %clang_cc1 -analyze -analyzer-checker=core,osx -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist +// RUN: %clang_analyze_cc1 -analyzer-checker=core,osx -analyzer-output=text -verify %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,osx -analyzer-output=plist-multi-file -analyzer-config path-diagnostics-alternate=false %s -o %t.plist // RUN: FileCheck --input-file=%t.plist %s typedef signed char BOOL; @@ -45,8 +45,8 @@ SCDynamicStoreRef anotherCreateRef(unsigned *err, unsigned x); CreateRefUndef(&storeRef, 4); //expected-note@-1{{Calling 'CreateRefUndef'}} //expected-note@-2{{Returning from 'CreateRefUndef'}} - CFRelease(storeRef); //expected-warning {{Function call argument is an uninitialized value}} - //expected-note@-1{{Function call argument is an uninitialized value}} + CFRelease(storeRef); //expected-warning {{1st function call argument is an uninitialized value}} + //expected-note@-1{{1st function call argument is an uninitialized value}} } @end @@ -918,12 +918,12 @@ static void CreateRefUndef(SCDynamicStoreRef *storeRef, unsigned x) { // CHECK-NEXT: </array> // CHECK-NEXT: <key>depth</key><integer>0</integer> // CHECK-NEXT: <key>extended_message</key> -// CHECK-NEXT: <string>Function call argument is an uninitialized value</string> +// CHECK-NEXT: <string>1st function call argument is an uninitialized value</string> // CHECK-NEXT: <key>message</key> -// CHECK-NEXT: <string>Function call argument is an uninitialized value</string> +// CHECK-NEXT: <string>1st function call argument is an uninitialized value</string> // CHECK-NEXT: </dict> // CHECK-NEXT: </array> -// CHECK-NEXT: <key>description</key><string>Function call argument is an uninitialized value</string> +// CHECK-NEXT: <key>description</key><string>1st function call argument is an uninitialized value</string> // CHECK-NEXT: <key>category</key><string>Logic error</string> // CHECK-NEXT: <key>type</key><string>Uninitialized argument value</string> // CHECK-NEXT: <key>check_name</key><string>core.CallAndMessage</string> |