Boost logo

Boost :

Subject: Re: [boost] [boost::endian] Summary of discussion #1
From: John Bytheway (jbytheway+boost_at_[hidden])
Date: 2010-06-02 14:48:49

On 02/06/10 16:37, Tomas Puverle wrote:
> Beside the two
> functions swap<>() and swap_in_place<>(),

On the naming issue: We already have a widely used and understood
meaning for two-argument swap which performs the swap in-place. For
that reason I would expect in-place semantics from your one-argument
swap too.

More subjectively, I prefer Rob's suggested endian_cast to swap. I
don't associate this operation with swapping, and indeed in some cases
there is no swapping involved.

John Bytheway

Boost list run by bdawes at, gregod at, cpdaniel at, john at