
8 May
2009
8 May
'09
5:45 p.m.
On Fri, May 8, 2009 at 13:33, Ross Levine <ross.levine@uky.edu> 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 (http://llvm.org/demo will demonstrate), so it's no slower than the non-standard way. ~ Scott