unreachable code: don't warn about empty statements
[smatch.git] / validation / sm_compare12.c
blob9bf8c662c69ccebb095dc46505de8d63e18b509d
1 #include "check_debug.h"
3 #define min_t(type, x, y) ({ \
4 type __min1 = (x); \
5 type __min2 = (y); \
6 __min1 < __min2 ? __min1: __min2; })
8 int a, b, c, d;
9 static int options_write(void)
11 a = min_t(int, b + c, d);
12 __smatch_compare(a, d);
13 __smatch_compare(a, b + c);
14 b++;
15 __smatch_compare(a, b + c);
19 * check-name: smatch compare #12
20 * check-command: smatch -I.. sm_compare12.c
22 * check-output-start
23 sm_compare12.c:12 options_write() a <= d
24 sm_compare12.c:13 options_write() a <= b + c
25 sm_compare12.c:15 options_write() a <none> b + c
26 * check-output-end