blob: a0a50cbc9343448cd84229b84f93a3b01872a14a [file] [log] [blame]
Ted Kremeneka4a57c12011-03-12 06:14:28 +00001// RUN: %clang_cc1 -analyze -analyzer-checker=core,deadcode.DeadStores,debug.Stats -verify -Wno-unreachable-code -analyzer-opt-analyze-nested-blocks %s
Tom Care4545b2d2010-09-10 00:44:44 +00002
3int foo();
4
Alp Toker6ed72512013-12-14 01:07:05 +00005int test() { // expected-warning-re{{test -> Total CFGBlocks: {{[0-9]+}} | Unreachable CFGBlocks: 0 | Exhausted Block: no | Empty WorkList: yes}}
Tom Care4545b2d2010-09-10 00:44:44 +00006 int a = 1;
7 a = 34 / 12;
8
9 if (foo())
10 return a;
11
12 a /= 4;
13 return a;
14}