Boost logo

Boost :

Subject: Re: [boost] Review Request: Algorithm.Sorting
From: Scott McMurray ([hidden])
Date: 2009-05-08 13:45:07

On Fri, May 8, 2009 at 13:33, Ross Levine <ross.levine_at_[hidden]> wrote:
> Also, couldn't you just use reinterpret_cast instead of memcpy? Or is there
> a problem with that?

See the archives. In short, the reinterpret-cast runs afoul of
aliasing rules, and in practice, compilers can optimize the memcpy
down to a bitcast anyways ( will demonstrate), so
it's no slower than the non-standard way.

~ Scott

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