
2 Jun
2010
2 Jun
'10
6:48 p.m.
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