1// RUN: %clang_cl_asan %Od %s %Fe%t
2// RUN: %run %t
3
4#include <windows.h>
5
6typedef struct _S {
7 unsigned int bf1:1;
8 unsigned int bf2:2;
9 unsigned int bf3:3;
10 unsigned int bf4:4;
11} S;
12
13int main(void) {
14 S *s = (S*)malloc(sizeof(S));
15 s->bf1 = 1;
16 s->bf2 = 2;
17 s->bf3 = 3;
18 s->bf4 = 4;
19 free(s);
20 return 0;
21}
22

source code of compiler-rt/test/asan/TestCases/Windows/bitfield.cpp