builtin_29_return_address.c (320B)
1 /* __builtin_return_address(0): the current function's return address, read 2 * from the spilled frame record. A real frame's return address is never null. 3 */ 4 __attribute__((noinline)) static void* ra0(void) { 5 return __builtin_return_address(0); 6 } 7 8 int test_main(void) { 9 void* r = ra0(); 10 return r != 0 ? 42 : 1; 11 }