File tree 1 file changed +3
-3
lines changed
datafusion/physical-expr-common/src/aggregate/groups_accumulator 1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -141,7 +141,7 @@ where
141
141
values : & [ ArrayRef ] ,
142
142
opt_filter : Option < & BooleanArray > ,
143
143
) -> Result < Vec < ArrayRef > > {
144
- let values = values[ 0 ] . as_primitive :: < T > ( ) ;
144
+ let values = values[ 0 ] . as_primitive :: < T > ( ) . clone ( ) ;
145
145
146
146
// Initializing state with starting values
147
147
let initial_state =
@@ -164,11 +164,11 @@ where
164
164
let ( dt, values_buf, original_nulls) = values. clone ( ) . into_parts ( ) ;
165
165
let nulls_buf =
166
166
NullBuffer :: union ( original_nulls. as_ref ( ) , Some ( & filter_nulls) ) ;
167
- & PrimitiveArray :: < T > :: new ( values_buf, nulls_buf) . with_data_type ( dt)
167
+ PrimitiveArray :: < T > :: new ( values_buf, nulls_buf) . with_data_type ( dt)
168
168
}
169
169
} ;
170
170
171
- let state_values = compute:: binary_mut ( initial_state, values, |mut x, y| {
171
+ let state_values = compute:: binary_mut ( initial_state, & values, |mut x, y| {
172
172
( self . prim_fn ) ( & mut x, y) ;
173
173
x
174
174
} ) ;
You can’t perform that action at this time.
0 commit comments