1 /* Test that gcc understands that the call to g might clobber i. */ 2 3 /* { dg-do run } */ 4 /* { dg-options "-O2 -fgnu89-inline" } */ 5 f()6__inline int f () 7 { 8 static int i; 9 int i2 = i; 10 i = i2 + 1; 11 return i; 12 } 13 g()14int g () { return f (); } 15 main()16int main () 17 { 18 if (f() != 1 19 || g() != 2 20 || f() != 3) 21 return 1; 22 return 0; 23 } 24