Issue #16166: Add PY_LITTLE_ENDIAN and PY_BIG_ENDIAN macros and unified

endianess detection and handling.
This commit is contained in:
Christian Heimes 2012-10-17 23:52:17 +02:00
parent 1e9af84e2e
commit 743e0cd6b5
15 changed files with 78 additions and 107 deletions

View file

@ -1664,11 +1664,8 @@ static const struct mformatdescr {
static enum machine_format_code
typecode_to_mformat_code(char typecode)
{
#ifdef WORDS_BIGENDIAN
const int is_big_endian = 1;
#else
const int is_big_endian = 0;
#endif
const int is_big_endian = PY_BIG_ENDIAN;
size_t intsize;
int is_signed;