(root)/
gcc-13.2.0/
gcc/
testsuite/
gcc.dg/
gnu2x-attr-syntax-2.c
       1  /* Test C2x attribute syntax.  Invalid uses of attributes with GNU C
       2     features.  */
       3  /* { dg-do compile } */
       4  /* { dg-options "-std=gnu2x -w" } */
       5  
       6  /* Attributes cannot be used as prefix attributes on old-style
       7     parameter declarations or on function declarators with identifier
       8     lists (removed from C2x).  */
       9  
      10  void (*f(a, b) [[]])() int a, b; { } /* { dg-error "expected" } */
      11  
      12  void f(x, y) int x; [[]] int y; { } /* { dg-error "expected" } */
      13  
      14  /* Nonempty attributes cannot be used as postfix attributes with
      15     __auto_type.  */
      16  __auto_type [[gnu::no_such_attr]] x = 1; /* { dg-error "'__auto_type' followed by" } */