Fix unexpected sign-extend conversion of pointer to integer