Apache DataFusion SQL Query Engine
minor: remove unused code in binary.rs (#6203)
Andrew Lamb5d3802fba057
diff --git a/datafusion/physical-expr/src/expressions/binary.rs b/datafusion/physical-expr/src/expressions/binary.rsindex 5a82be5e2e..5ca7b9ddf2 100644--- a/datafusion/physical-expr/src/expressions/binary.rs+++ b/datafusion/physical-expr/src/expressions/binary.rs@@ -671,32 +671,6 @@ impl PhysicalExpr for BinaryExpr {let schema = batch.schema();let input_schema = schema.as_ref();- match (&left_value, &left_data_type, &right_value, &right_data_type) {- // Types are equal => valid- // Decimal types can be different but still valid as we coerce them to the same type later- (_, l, _, r) if l == r || (is_decimal(l) && is_decimal(r)) => {}- // Allow comparing a dictionary value with its corresponding scalar value- (- ColumnarValue::Array(_),- DataType::Dictionary(_, dict_t),- ColumnarValue::Scalar(_),- scalar_t,- )- | (- ColumnarValue::Scalar(_),- scalar_t,- ColumnarValue::Array(_),- DataType::Dictionary(_, dict_t),- ) if dict_t.as_ref() == scalar_t- || (is_decimal(dict_t.as_ref()) && is_decimal(scalar_t)) => {}- _ => {- return Err(DataFusionError::Internal(format!(- "Cannot evaluate binary expression {:?} with types {:?} and {:?}",- self.op, left_data_type, right_data_type- )));- }- }-// Coerce decimal types to the same scale and precisionlet coerced_type = coercion_decimal_mathematics_type(&self.op,