(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
cpp/
trad/
recurse-3.c
       1  /* Tests that macros that look recursive but are not are accepted.  */
       2  
       3  /* { dg-do preprocess } */
       4  
       5  #define g(x) x
       6  g(g(g(g(g(g(g))))));	       /* { dg-bogus "detected recursion" } */
       7  
       8  /* This macro gets longer with each loop, to thwart tests for
       9     recursion based on length.  */
      10  #define f(a,b,c,d,e,f,g,h,i) a(b,c,d,e,f,g,h,i,2 3 4 5)
      11  f(f,f,f,f,f,f,f,f,f)	       /* { dg-bogus "detected recursion" } */
      12  
      13  /* The above cases should be enough, but this is taken from cccp
      14     sources so let's try it too.  */
      15  #define foo(x,y) bar (x (y,0), y)
      16  foo (foo, baz);	       /* { dg-bogus "detected recursion" } */
      17  
      18  #define mac mac/**/ro
      19  mac		       /* { dg-bogus "detected recursion" } */
      20  
      21  #define mac2 mac2
      22  "mac2" 		       /* { dg-bogus "detected recursion" } */
      23  
      24  #define macro "macro
      25  macro mac2	       /* { dg-bogus "detected recursion" } */