
5 Jun
2010
5 Jun
'10
1:01 p.m.
Hi Vicente,
I see that there are specific classes for native endian, endian<endianness::native, ...>.
I was wondering if instead of defining a separated class we can not define endianness::native depending on the ENDIAN of the host and remove the explicit definition.
# ifdef BOOST_BIG_ENDIAN BOOST_SCOPED_ENUM_START(endianness) { big, little, native=big }; BOOST_SCOPED_ENUM_END #else BOOST_SCOPED_ENUM_START(endianness) { big, little, native=little }; BOOST_SCOPED_ENUM_END #endif
Interesting. Seems like a good idea!
Will this break the design?
Off-hand, I can't think of any reason. I've been very tied up with other projects. I'll try to look at this in more detail over the next few days. Thanks, --Beman