Boost logo

Boost :

Subject: Re: [boost] [boost::endian] Request for comments/interest
From: Kim Barrett (kab.conundrums_at_[hidden])
Date: 2010-05-27 12:18:15


On May 27, 2010, at 10:50 AM, Stewart, Robert wrote:
> It isn't clear that directionality should be parameterized.
>
> That leads to this:
>
> enum endianness { big_endian, little_endian };
>
> template <endianness E, class T, class U>
> void
> from(T &, U);
>
> template <endianness E, class T>
> void
> from(T &);
>
> [...]
> IOW, the spelling changes from "{from,to}_{big,little}_endian" to "{from,to}<{big,little}_endian>."

Yes, something like that was what I had in mind.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk