Possible gcc bug in strict type aliasing

Vincent Lefevre vincent+gcc@vinc17.org
Tue Sep 27 13:46:00 GMT 2016


On 2016-09-27 15:38:52 +0200, Vincent Lefevre wrote:
> A solution could be:
> 
>   p2 = (T2 *) (void *) p1;

Oops, that would be incorrect too.

-- 
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)



More information about the Gcc-help mailing list