[analyzer] fix test case expected warning
authorMikhail R. Gadelha <mikhail.ramalho@gmail.com>
Thu, 28 Jun 2018 22:08:44 +0000 (22:08 +0000)
committerMikhail R. Gadelha <mikhail.ramalho@gmail.com>
Thu, 28 Jun 2018 22:08:44 +0000 (22:08 +0000)
After r335814, the constraint manager is no longer generating a false bug report
about the division by zero in the test case.

This patch removes the expected false bug report.

llvm-svn: 335932

clang/test/Analysis/z3-crosscheck.c

index 66f778d..67d4104 100644 (file)
@@ -21,22 +21,14 @@ void f(int *a, int *b) {
   if ((a - b) == 0)
     c = 0;
   if (a != b)
-#ifdef NO_CROSSCHECK
-    g(3 / c); // expected-warning {{Division by zero}}
-#else
     g(3 / c); // no-warning
-#endif
 }
 
 _Bool nondet_bool();
 
 void h(int d) {
   int x, y, k, z = 1;
-#ifdef NO_CROSSCHECK
   while (z < k) { // expected-warning {{The right operand of '<' is a garbage value}}
-#else
-  while (z < k) { // expected-warning {{The right operand of '<' is a garbage value}}
-#endif
     z = 2 * z;
   }
 }