Corrected type-punning issue