HomeFreeBSD

Define max_align_t for C11.

Description

Define max_align_t for C11.

libc++'s stddef.h includes an existing definition of max_align_t for
C++11, but it is only defined for C++, not for C. In addition, GCC and
clang both define an alternate version of max_align_t that uses a
union of multiple types rather than a plain long double as in libc++.
This adds a __max_align_t to <sys/_types.h> that matches the GCC and
clang definition that is mapped to max_align_t in <stddef.h>.

PR: 210890
Reviewed by: dim
MFC after: 1 month
Differential Revision: https://reviews.freebsd.org/D8194

Details

Provenance
jhbAuthored on
Reviewer
dim
Differential Revision
D8194: Define max_align_t for C11.
Parents
rS307755: swapoff: Remove only late devices with -aL.
Branches
Unknown
Tags
Unknown