mirror of git://git.musl-libc.org/musl
setjmp.h: add struct tag for sigjmp_buf (GCC C++ compatibility)
the anonymous struct typedef with array notation breaks with GCC in C++ mode: error: non-local function 'static<anonymous struct> (& boost::signal_handler::jump_buffer())[1]' uses anonymous type this is a known GCC issue, as search results for that error msg suggest. since this is hard to work around in the calling C++ code, a fix in musl is preferable.
This commit is contained in:
parent
2ba3f44db5
commit
d84923d89e
|
@ -13,7 +13,7 @@ extern "C" {
|
||||||
#if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
|
#if defined(_POSIX_SOURCE) || defined(_POSIX_C_SOURCE) \
|
||||||
|| defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) \
|
|| defined(_XOPEN_SOURCE) || defined(_GNU_SOURCE) \
|
||||||
|| defined(_BSD_SOURCE)
|
|| defined(_BSD_SOURCE)
|
||||||
typedef struct {
|
typedef struct __sigjmp_buf {
|
||||||
jmp_buf __jb;
|
jmp_buf __jb;
|
||||||
unsigned long __fl;
|
unsigned long __fl;
|
||||||
unsigned long __ss[128/sizeof(long)];
|
unsigned long __ss[128/sizeof(long)];
|
||||||
|
|
Loading…
Reference in New Issue