[PATCH] fix KJS crash on some more strict platforms
Maks Orlovich
mo002j at mail.rochester.edu
Tue Dec 16 23:00:32 GMT 2003
> > union { char NaN_Bytes[8];
> > double NaN_Double;
> > } NaN_Representation;
> >
> > which presumably forces the whole union to the alignment of the strictest
> > type. Neater than using a gcc extension.
>
> Newer gcc's (e.g. 3.3.x) does not guarantee that this will work under all
> circumstances and would force you to compile with -fno-strict-aliasing.
Huh? Accessing fields of unions is perfectly legal. In fact you don't even
need the union to access something through a char*
More information about the kde-core-devel
mailing list