gcc/testsuite/gcc.dg/pr38338.c
raw| 1 | /* PR middle-end/38338 */ |
| 2 | /* { dg-options "-O0" } */ |
| 3 | /* { dg-options "-O0 -fPIC" { target fpic } } */ |
| 4 | /* { dg-require-effective-target untyped_assembly } */ |
| 5 | |
| 6 | typedef void (*fnp) (void); |
| 7 | |
| 8 | static char |
| 9 | foo (char x) |
| 10 | { |
| 11 | return x; |
| 12 | } |
| 13 | |
| 14 | static void * |
| 15 | bar (char x) |
| 16 | { |
| 17 | void *args = __builtin_apply_args (); |
| 18 | return __builtin_apply ((fnp) foo, args, sizeof (void *)); |
| 19 | } |