https://gcc.gnu.org/bugzilla/show_bug.cgi?id=63907
Andrew Pinski <pinskia at gcc dot gnu.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|WAITING |RESOLVED Known to work| |11.1.0 Target Milestone|--- |11.0 Component|libitm |c++ --- Comment #14 from Andrew Pinski <pinskia at gcc dot gnu.org> --- GCC 11+ accepts this code now: #define PTHREAD_COND_INITIALIZER {{ 0, 0 }, 0, "", 0} struct _pthread_fastlock { long int __status; int __spinlock; }; typedef struct _pthread_descr_struct *_pthread_descr; __extension__ typedef long long __pthread_cond_align_t; typedef struct { struct _pthread_fastlock __c_lock; _pthread_descr __c_waiting; char __padding[48 - sizeof (struct _pthread_fastlock) - sizeof (_pthread_descr) - sizeof (__pthread_cond_align_t)]; __pthread_cond_align_t __align; } pthread_cond_t; struct S{ pthread_cond_t x; /* g++ 7.3: error: no matching function for call to 'pthread_cond_t::pthread_cond_t(<brace-enclosed initializer list>)' * g++ 4.5.3: error: could not convert '{{0, 0}, 0, "", 0}' to 'pthread_cond_t' */ S() : x (PTHREAD_COND_INITIALIZER) {} }; So I think we can close this as fixed for GCC 11. Also I doubt anyone has the older glibc around either.