blob: 7dd0c93c0d65bb2145f63dc28c16a7820ce4a8cc [file] [log] [blame]
njn25e49d8e72002-09-23 09:36:25 +00001
2#include <stdio.h>
3
4/* Static and global vars are inited to zero, non-static local vars aren't. */
5
6int g;
7static int gs;
8
9int main(void)
10{
11 int l;
12 static int ls;
13
14 if (gs == 0xDEADBEEF) printf("1!\n");
15 if (g == 0xDEADBEEF) printf("2!\n");
16 if (ls == 0xDEADBEEF) printf("3!\n");
17 if (l == 0xDEADBEEF) printf("4!\n"); // complains
18
19 return 0;
20}