-
Notifications
You must be signed in to change notification settings - Fork 10
Open
Description
This test checks whether __ORDER_BIG_ENDIAN__ is defined at all, but this predefined macro is not intended for that use case. It is identical to the custom IS_BIG_ENDIAN macro in the same file and is expected to be compared against __BYTE_ORDER__.
The current code unconditionally sets the byte order to big endian. The test probably should be:
# if defined(__BYTE_ORDER__)
# define PLATFORM_BYTE_ORDER __BYTE_ORDER__
# elif defined(__BIG_ENDIAN)
# define PLATFORM_BYTE_ORDER IS_BIG_ENDIAN
# else
# define PLATFORM_BYTE_ORDER IS_LITTLE_ENDIAN
# endif
Metadata
Metadata
Assignees
Labels
No labels