Computes the output interval for the given boolean expression based on statically available information. # Arguments `predicate` - The boolean expression to analyze `is_null` - A callback function that provides additional nullability information for expressions. When called with an expression, it should return: - `Some(true)` if the expression is known to evaluate to NULL - `Some(false)` if the
(
predicate: &Expr,
certainly_null_expr: Option<&Expr>,
input_schema: &dyn ExprSchema,
)
| 47 | /// predicate can evaluate to. |
| 48 | /// |
| 49 | pub(super) fn evaluate_bounds( |
| 50 | predicate: &Expr, |
| 51 | certainly_null_expr: Option<&Expr>, |
| 52 | input_schema: &dyn ExprSchema, |
| 53 | ) -> Result<NullableInterval> { |
| 54 | let evaluator = PredicateBoundsEvaluator { |
| 55 | input_schema, |
| 56 | certainly_null_expr, |
| 57 | }; |
| 58 | evaluator.evaluate_bounds(predicate) |
| 59 | } |
| 60 | |
| 61 | struct PredicateBoundsEvaluator<'a> { |
| 62 | input_schema: &'a dyn ExprSchema, |
no test coverage detected
searching dependent graphs…