Files
semi-libc/include
Rich Felker 97d35a552e move __BYTE_ORDER definition to alltypes.h
this change is motivated by the intersection of several factors.
presently, despite being a nonstandard header, endian.h is exposing
the unprefixed byte order macros and functions only if _BSD_SOURCE or
_GNU_SOURCE is defined. this is to accommodate use of endian.h from
other headers, including bits headers, which need to define structure
layout in terms of endianness. with time64 switch-over, even more
headers will need to do this.

at the same time, the resolution of Austin Group issue 162 makes
endian.h a standard header for POSIX-future, requiring that it expose
the unprefixed macros and the functions even in standards-conforming
profiles. changes to meet this new requirement would break existing
internal usage of endian.h by causing it to violate namespace where
it's used.

instead, have the arch's alltypes.h define __BYTE_ORDER, either as a
fixed constant or depending on the right arch-specific predefined
macros for determining endianness. explicit literals 1234 and 4321 are
used instead of __LITTLE_ENDIAN and __BIG_ENDIAN so that there's no
danger of getting the wrong result if a macro is undefined and
implicitly evaluates to 0 at the preprocessor level.

the powerpc (32-bit) bits/endian.h being removed had logic for varying
endianness, but our powerpc arch has never supported that and has
always been big-endian-only. this logic is not carried over to the new
__BYTE_ORDER definition in alltypes.h.
2019-10-17 15:55:15 -04:00
..
2013-07-03 18:07:50 +02:00
2012-05-06 16:35:32 -04:00
2016-08-30 16:39:54 -04:00
2011-02-12 00:22:29 -05:00
2012-09-08 18:16:33 -04:00
2011-02-12 00:22:29 -05:00
2014-06-21 19:24:15 -04:00
2011-02-14 21:59:38 -05:00
2012-05-06 16:35:32 -04:00
2011-02-12 00:22:29 -05:00
2011-02-12 00:22:29 -05:00
2019-08-30 16:21:36 -04:00
2019-08-08 11:33:18 -04:00
2018-06-26 16:59:12 -04:00
2014-07-31 02:38:23 -04:00
2011-04-05 15:40:36 -04:00
2019-03-13 10:42:57 -04:00
2011-02-12 00:22:29 -05:00
2016-10-20 16:55:32 -04:00
2013-01-04 20:36:34 +01:00