forked from OSchip/llvm-project
The second check point in the old test case was invalid.
llvm-svn: 101983
This commit is contained in:
parent
465dfb2705
commit
f29231ece0
|
@ -1,12 +1,14 @@
|
|||
// RUN: %clang_cc1 -analyze -analyzer-check-objc-mem -analyzer-store region -verify %s
|
||||
|
||||
void f1() {
|
||||
int *n1 = new int;
|
||||
if (*n1) { // expected-warning {{Branch condition evaluates to a garbage value}}
|
||||
}
|
||||
|
||||
int *n2 = new int(3);
|
||||
if (*n2) { // no-warning
|
||||
int *n = new int;
|
||||
if (*n) { // expected-warning {{Branch condition evaluates to a garbage value}}
|
||||
}
|
||||
}
|
||||
|
||||
void f2() {
|
||||
int *n = new int(3);
|
||||
if (*n) { // no-warning
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue