| lh | 9ed821d | 2023-04-07 01:36:19 -0700 | [diff] [blame] | 1 | #include <stdio.h> |
| 2 | |||||
| 3 | extern int foo (void); | ||||
| 4 | extern int bar (void); | ||||
| 5 | |||||
| 6 | void | ||||
| 7 | __attribute__ ((constructor)) | ||||
| 8 | init (void) | ||||
| 9 | { | ||||
| 10 | (void) (foo () - bar ()); | ||||
| 11 | } | ||||
| 12 | |||||
| 13 | static void | ||||
| 14 | __attribute__ ((destructor)) | ||||
| 15 | fini (void) | ||||
| 16 | { | ||||
| 17 | putchar ('2'); | ||||
| 18 | } | ||||