haohuaijin commented on code in PR #8833:
URL: https://github.com/apache/arrow-datafusion/pull/8833#discussion_r1452270992


##########
datafusion/optimizer/src/utils.rs:
##########
@@ -92,6 +94,21 @@ pub fn log_plan(description: &str, plan: &LogicalPlan) {
     trace!("{description}::\n{}\n", plan.display_indent_schema());
 }
 
+/// check whether the expression is volatile predicates
+pub(crate) fn is_volatile_expression(e: &Expr) -> Result<bool> {
+    let mut is_volatile_expr = false;
+    e.apply(&mut |expr| {
+        Ok(if is_volatile(expr)? {
+            is_volatile_expr = true;
+            VisitRecursion::Stop
+        } else {
+            VisitRecursion::Continue
+        })
+    })
+    .unwrap();

Review Comment:
   Thanks for pointing this out. I forgot to change it when I moved the code.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to