* support/regression/tests/bug-478094.c: Added.
[fw/sdcc] / support / regression / tests / bug-478094.c
1 /* Tests a commit problem.
2  */
3 #include <testfwk.h>
4
5
6
7 int foo = 16; 
8
9 extern void f( int x ); 
10
11 void g(int bar) 
12
13   int a = 0; 
14   int b = 0; 
15
16   while(1) { 
17     switch(bar) { 
18     case 0: 
19       --foo; 
20       f(foo); 
21       break; 
22     case 1: 
23       ++foo; 
24       f(foo); 
25       break; 
26     case 2: 
27       ++a; 
28       f(a); 
29       break; 
30     case 3: 
31       ++b; 
32       f(b); 
33       break; 
34     } 
35   } 
36