Remove some no-op static_casts.