param_key: fix container of when no struct member is referenced
[smatch.git] / validation / bug-rshift-ub.c
blob7654abbd8f9c2d4863570be995fb45d41b770021
1 enum a {
2 A = ~0ULL,
3 };
5 static enum a a = A;
7 /*
8 * check-name: bug-rshift-ub
9 * check-description:
10 * This test trigger(ed) a bug on x86 caused by a
11 * full width shift (which is UB), expecting to get
12 * 0 but giving the unshifted value and as result
13 * the type is invalid:
14 * warning: incorrect type in initializer (invalid types)
15 * expected bad type enum a static [toplevel] a