Monday, July 21, 2014

Test endianness

#include<stdint.h>
typedef uint16_t t2u;

/*1, if little; 0, if big*/
bool constexpr bEL()noexcept{return(t2u&)"AB"==(t2u)0x4241;}

No comments:

Post a Comment