Watch out for undefined behaviour.