Skip to content

Commit 099dc05

Browse files
committed
comment about nullability
1 parent fdcb31d commit 099dc05

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

datafusion/expr/src/expr_schema.rs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -583,12 +583,13 @@ impl ExprSchemable for Expr {
583583
Expr::Cast(Cast { expr, field }) => expr
584584
.to_field(schema)
585585
.map(|(_, f)| {
586+
// This currently propagates the nullability of the input
587+
// expression as the resulting physical expression does
588+
// not currently consider the nullability specified here
586589
f.as_ref()
587590
.clone()
588591
.with_data_type(field.data_type().clone())
589592
.with_metadata(f.metadata().clone())
590-
// TODO: should nullability be overridden here or derived from the
591-
// input expression?
592593
})
593594
.map(Arc::new),
594595
Expr::Placeholder(Placeholder {

0 commit comments

Comments
 (0)