aboutsummaryrefslogtreecommitdiff
path: root/test/Analysis/fields.c
blob: 72de12c4dcc1321f848ce46c3c343b0b7cd7218f (plain)
1
2
3
4
5
6
7
8
9
10
// RUN: clang -checker-cfref %s -verify &&
// RUN: clang -checker-simple %s -verify

unsigned foo();
typedef struct bf { unsigned x:2; } bf;
void bar() {
  bf y;
  *(unsigned*)&y = foo();
  y.x = 1;
}