-
Notifications
You must be signed in to change notification settings - Fork 1
/
dcl.c
98 lines (75 loc) · 1.11 KB
/
dcl.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
struct a {
int v;
char b;
}; // 8
struct b {
int v;
char b;
int c;
}; // 12
struct c{
char d;
char a[10];
char b;
int c;
}; // 16
union u {
char a;
int b;
char c[5];
struct c ll;
};
int func(char p1, int p2, void * p3)
{
int temp;
p1 = 'a';
p2 = 0;
p3 = (void *)0;
return 0;
}
int main()
{
char str[12];
struct a aa;
struct b bb;
struct c cc;
struct c *pc = &cc;
union u uu;
char v1;
int v2 = -1;
unsigned int v3 = 7;
int nn,mm = 0;
str[6] = 'c';
aa.b = 'x';
pc->c = 88;
pc->a[4] = 'v';
uu.ll.a[3] = 'l';
v2 = nn++;
v2 = nn--;
v2 = --nn;
v2 = ++nn;
v2 = nn + mm;
v2 = nn - mm;
v2 = nn * mm;
v2 = nn / mm;
v2 = nn % mm;
v2 = nn & mm;
v2 = nn | mm;
v2 = ~nn;
v2 = nn ^ mm;
v2 = nn >> 1;
v2 = nn << 1;
v2 += mm;
v2 -= mm;
v2 *= mm;
v2 /= mm;
v2 %= mm;
v2 >>= mm;
v2 <<= mm;
v2 &= mm;
v2 |= mm;
v2 ^= mm;
v2=v2=mm, mm=nn;
func(v1, v2, (void*)pc);
return 0;
}