Skip to content

Commit

Permalink
Delete unused HirScalarExpr::visit1_mut
Browse files Browse the repository at this point in the history
  • Loading branch information
ggevay committed Jan 22, 2025
1 parent 1c8b234 commit 7e1e1c5
Showing 1 changed file with 0 additions and 33 deletions.
33 changes: 0 additions & 33 deletions src/sql/src/plan/hir.rs
Original file line number Diff line number Diff line change
Expand Up @@ -3097,39 +3097,6 @@ impl HirScalarExpr {
mem::replace(self, HirScalarExpr::literal_null(ScalarType::String))
}

#[deprecated = "Use `VisitChildren<HirScalarExpr>::visit_children` instead."]
pub fn visit1_mut<F>(&mut self, mut f: F)
where
F: FnMut(&mut Self),
{
use HirScalarExpr::*;
match self {
Column(..) | Parameter(..) | Literal(..) | CallUnmaterializable(..) => (),
CallUnary { expr, .. } => f(expr),
CallBinary { expr1, expr2, .. } => {
f(expr1);
f(expr2);
}
CallVariadic { exprs, .. } => {
for expr in exprs {
f(expr);
}
}
If { cond, then, els } => {
f(cond);
f(then);
f(els);
}
Exists(..) | Select(..) => (),
Windowing(expr) => {
let _ = expr.visit_expressions_mut(&mut |e| -> Result<(), ()> {
f(e);
Ok(())
});
}
}
}

#[deprecated = "Redefine this based on the `Visit` and `VisitChildren` methods."]
/// Visits the column references in this scalar expression.
///
Expand Down

0 comments on commit 7e1e1c5

Please sign in to comment.