2 ms·
The parent comment seems to be saying that C99 does allow type punning with a union, with an explicit clarification as you say. In C89 it was ambiguous and in C
by quietbritishjim 7y ago
The parent comment seems to be saying that C99 does allow type punning with a union, with an explicit clarification as you say. In C89 it was ambiguous and in C++ it is explicitly disallowed (you are supposed to use memcpy).
- quietbritishjim 7y agoSorry, I misread the parent comment. Now it's too late to delete mine, please ignore.