3 ms·
Interestingly, g++ gives out a warning (correctly) when compiled with -O2, but not by default (-O0): warning: dereferencing type-punned pointer will break
by satbyy 11y ago
Interestingly, g++ gives out a warning (correctly) when compiled with -O2, but not by default (-O0):
warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
So, you're right indeed.