From f389c31ac95c1b4c32c028e06de5a13f29a1569e Mon Sep 17 00:00:00 2001 From: bit-aloo Date: Fri, 25 Jul 2025 17:55:53 +0530 Subject: [PATCH] remove bool from sum variant in AggContext --- core/types.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/types.rs b/core/types.rs index 56822c34b..5cbe08152 100644 --- a/core/types.rs +++ b/core/types.rs @@ -498,7 +498,7 @@ impl Value { #[derive(Debug, Clone, PartialEq)] pub enum AggContext { Avg(Value, Value), // acc and count - Sum(Value, bool), // acc and has_non_numeric + Sum(Value), Count(Value), Max(Option), Min(Option), @@ -522,7 +522,7 @@ impl AggContext { pub fn final_value(&self) -> &Value { match self { Self::Avg(acc, _count) => acc, - Self::Sum(acc, _) => acc, + Self::Sum(acc) => acc, Self::Count(count) => count, Self::Max(max) => max.as_ref().unwrap_or(&NULL), Self::Min(min) => min.as_ref().unwrap_or(&NULL), @@ -596,7 +596,7 @@ impl PartialOrd for AggContext { fn partial_cmp(&self, other: &AggContext) -> Option { match (self, other) { (Self::Avg(a, _), Self::Avg(b, _)) => a.partial_cmp(b), - (Self::Sum(a, _), Self::Sum(b, _)) => a.partial_cmp(b), + (Self::Sum(a), Self::Sum(b)) => a.partial_cmp(b), (Self::Count(a), Self::Count(b)) => a.partial_cmp(b), (Self::Max(a), Self::Max(b)) => a.partial_cmp(b), (Self::Min(a), Self::Min(b)) => a.partial_cmp(b),