Use Primitive::$ARRAY for array type hint
Implement cast()