Fix type casts for 7.1 output