Skip to content

Commit dbf832a

Browse files
committed
Drop redundant param from WindowFunctionDefinition::return_field
It became redundant when `input_expr_types: &[DataType]` was replaced with `input_expr_fields: &[Field]`, i.e. in 577c424 commit. The benefit of passing in a "field" is that it combines data type and nullable attribute.
1 parent bb2d90e commit dbf832a

File tree

2 files changed

+1
-7
lines changed

2 files changed

+1
-7
lines changed

datafusion/expr/src/expr.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1039,7 +1039,6 @@ impl WindowFunctionDefinition {
10391039
pub fn return_field(
10401040
&self,
10411041
input_expr_fields: &[FieldRef],
1042-
_input_expr_nullable: &[bool],
10431042
display_name: &str,
10441043
) -> Result<FieldRef> {
10451044
match self {

datafusion/physical-plan/src/windows/mod.rs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -69,12 +69,7 @@ pub fn schema_add_window_field(
6969
.iter()
7070
.map(|e| Arc::clone(e).as_ref().return_field(schema))
7171
.collect::<Result<Vec<_>>>()?;
72-
let nullability = args
73-
.iter()
74-
.map(|e| Arc::clone(e).as_ref().nullable(schema))
75-
.collect::<Result<Vec<_>>>()?;
76-
let window_expr_return_field =
77-
window_fn.return_field(&fields, &nullability, fn_name)?;
72+
let window_expr_return_field = window_fn.return_field(&fields, fn_name)?;
7873
let mut window_fields = schema
7974
.fields()
8075
.iter()

0 commit comments

Comments
 (0)