2003-12-26 Guilhem Lavaux <guilhem@kaffe.org>
[official-gcc.git] / gcc / testsuite / gcc.c-torture / execute / 20020107-1.c
blobd5bbcc413243999c00faca3bbfd4cea0cf00488e
1 /* This testcase failed because - 1 - buf was simplified into ~buf and when
2 later expanding it back into - buf + -1, -1 got lost. */
4 extern void abort (void);
5 extern void exit (int);
7 static void
8 bar (int x)
10 if (!x)
11 abort ();
14 char buf[10];
16 inline char *
17 foo (char *tmp)
19 asm ("" : "=r" (tmp) : "0" (tmp));
20 return tmp + 2;
23 int
24 main (void)
26 bar ((foo (buf) - 1 - buf) == 1);
27 exit (0);