(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
pr99122-2.c
       1  /* { dg-do compile } */
       2  /* { dg-options "-O2 -g -w" } */
       3  /* { dg-require-effective-target alloca } */
       4  
       5  static int foo ();
       6  
       7  int
       8  bar (int n)
       9  {
      10    struct S { char a[n]; } x;
      11    __builtin_memset (x.a, 0, n);
      12    return foo (n, x);
      13  }
      14  
      15  static inline int
      16  foo (int n, struct T { char a[n]; } b)
      17  {
      18    int r = 0, i;
      19    for (i = 0; i < n; i++)
      20      r += b.a[i];
      21    return r;
      22  }