llvm-project
e566313a - [libc][signal] clean up usage of sighandler_t (#125745)

Commit
1 year ago
[libc][signal] clean up usage of sighandler_t (#125745) `man 3 signal`'s declaration has a face _only a mother could love_. sighandler_t and __sighandler_t are not defined in the C standard, or POSIX. They are helpful typedefs provided by glibc and the Linux kernel UAPI headers respectively since working with function pointers' syntax can be painful. But we should not rely on them; in C++ we have `auto*` and `using` statements. Remove the proxy header, and only include a typedef for sighandler_t when targeting Linux, for compatibility with glibc. Fixes: #125598
Parents
Loading