Implement the C++2a feature "A compile time endian-ness detection idiom"
Howard's suggested implementation is:
enum class endian
{
#ifdef _WIN32
little = 0, big = 1, native = little
#else
little = __ORDER_LITTLE_ENDIAN__, big = __ORDER_BIG_ENDIAN__ native = __BYTE_ORDER__,
#endif
};
but libc++ has it's own macros that have done the work to detect this.
The other option would be to rip out _LIBCPP_LITTLE_ENDIAN and _LIBCPP_BIG_ENDIAN, which is tempting, but that would entail changes in code that has to compile for earlier C++ language versions.
(Apologies for double commenting, did not notice that it was in phab until after replying)
I'm probably wrong, but if this is a C++2a proposal, shouldn't this
be
?