Cleanup some useless casts