pub fn requires_nested_struct_cast(
source_type: &DataType,
target_type: &DataType,
) -> boolExpand description
Returns true if casting from source_type to target_type requires
name-based nested struct casting logic, rather than Arrow’s standard cast.
This is the case when both types are struct types, or both are the same container type (List, LargeList, ListView, LargeListView, Dictionary) wrapping types that recursively contain structs.
Use this predicate at both planning time (to decide whether to apply struct
compatibility validation) and execution time (to decide whether to route
through cast_column instead of Arrow’s generic cast).