From 4ad09eabd355120fb0f169c89acd372586444d5e Mon Sep 17 00:00:00 2001 From: Weijie Guo Date: Fri, 13 Oct 2023 13:53:34 +0800 Subject: [PATCH] refactor: *_horizontal dependent on reduce_expr to expression architecture (#11685) --- crates/polars-plan/src/dsl/function_expr/mod.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/crates/polars-plan/src/dsl/function_expr/mod.rs b/crates/polars-plan/src/dsl/function_expr/mod.rs index 3c2d241d07a5..24a61df540f0 100644 --- a/crates/polars-plan/src/dsl/function_expr/mod.rs +++ b/crates/polars-plan/src/dsl/function_expr/mod.rs @@ -258,6 +258,9 @@ pub enum FunctionExpr { ForwardFill { limit: FillNullLimit, }, + SumHorizontal, + MaxHorizontal, + MinHorizontal, #[cfg(feature = "ewma")] EwmMean { options: EWMOptions, @@ -270,9 +273,6 @@ pub enum FunctionExpr { EwmVar { options: EWMOptions, }, - SumHorizontal, - MaxHorizontal, - MinHorizontal, } impl Hash for FunctionExpr { @@ -772,15 +772,15 @@ impl From for SpecialEq> { }, BackwardFill { limit } => map!(dispatch::backward_fill, limit), ForwardFill { limit } => map!(dispatch::forward_fill, limit), + SumHorizontal => map_as_slice!(dispatch::sum_horizontal), + MaxHorizontal => wrap!(dispatch::max_horizontal), + MinHorizontal => wrap!(dispatch::min_horizontal), #[cfg(feature = "ewma")] EwmMean { options } => map!(ewm::ewm_mean, options), #[cfg(feature = "ewma")] EwmStd { options } => map!(ewm::ewm_std, options), #[cfg(feature = "ewma")] EwmVar { options } => map!(ewm::ewm_var, options), - SumHorizontal => map_as_slice!(dispatch::sum_horizontal), - MaxHorizontal => wrap!(dispatch::max_horizontal), - MinHorizontal => wrap!(dispatch::min_horizontal), } } }