rename cast() to transform() for clarity