Remove some C-style casts