xref: /csrg-svn/old/dbx/tests/cc/nested.c (revision 44083)
1*44083Sbostic /*
2*44083Sbostic  * Test of nested blocks.
3*44083Sbostic  */
4*44083Sbostic 
5*44083Sbostic int i;
6*44083Sbostic 
main()7*44083Sbostic main ()
8*44083Sbostic {
9*44083Sbostic     i = 3;
10*44083Sbostic     sub();
11*44083Sbostic }
12*44083Sbostic 
sub()13*44083Sbostic sub ()
14*44083Sbostic {
15*44083Sbostic     int i, j;
16*44083Sbostic 
17*44083Sbostic     for (i = 1; i <= 10; i++) {
18*44083Sbostic 	int j;
19*44083Sbostic 
20*44083Sbostic 	j = j + i;
21*44083Sbostic     }
22*44083Sbostic     j = 0;
23*44083Sbostic     for (i = 11; i <= 20; i++) {
24*44083Sbostic 	j = j + i;
25*44083Sbostic     }
26*44083Sbostic }
27*44083Sbostic 
after()28*44083Sbostic after ()
29*44083Sbostic {
30*44083Sbostic     int a;
31*44083Sbostic 
32*44083Sbostic     a = 3;
33*44083Sbostic }
34