Has anyone tested the recent stdalign.h stuff with clang? We got a report below regarding it. Do we need to replace clang's stdalign.h with a more feature-ful gnulib replacement?
/Simon Elias Pipping <invalid.nore...@gnu.org> writes: > URL: > <http://savannah.gnu.org/support/?107896> > > Summary: gnutls 3.0.8 fails to compile with clang > Project: GnuTLS > Submitted by: pipping > Submitted on: Wed 30 Nov 2011 12:38:29 GMT > Category: None > Priority: 5 - Normal > Severity: 3 - Normal > Status: None > Privacy: Public > Assigned to: None > Originator Email: > Open/Closed: Open > Discussion Lock: Any > Operating System: None > > _______________________________________________________ > > Details: > > Earlier versions worked. (My theory for) the reason this version does not > work > for: > > gl/argp-parse.c uses alignof(); for that, <stdalign.h> is included. a usable > stdalign.h is also shipped with gnutls for use with compilers that don't > come with such a header yet. > > clang does have such a header but it only defines alignas(), not alignof(). > > here is the actual error: > > argp-parse.c:490:41: error: expected expression > csum = alignto (gsum + clen, alignof (struct option)); > ^ > > And this is what /usr/lib64/clang/3.1/include/stdalign.h contains for me > (aside from the copyright header and the include guards): > > #define alignas _Alignas > #define __alignas_is_defined 1 > > > > > > _______________________________________________________ > > Reply to this item at: > > <http://savannah.gnu.org/support/?107896> > > _______________________________________________ > Message sent via/by Savannah > http://savannah.gnu.org/