Fix redundant casts.