Rewrites all inputs for an Extension node "in place" (it currently has to copy values because there are no APIs for in place modification) Should be removed when we have an API for in place modifications of the extension to avoid these copies
(
extension: Extension,
f: F,
)
| 362 | /// Should be removed when we have an API for in place modifications of the |
| 363 | /// extension to avoid these copies |
| 364 | fn rewrite_extension_inputs<F: FnMut(LogicalPlan) -> Result<Transformed<LogicalPlan>>>( |
| 365 | extension: Extension, |
| 366 | f: F, |
| 367 | ) -> Result<Transformed<Extension>> { |
| 368 | let Extension { node } = extension; |
| 369 | |
| 370 | node.inputs() |
| 371 | .into_iter() |
| 372 | .cloned() |
| 373 | .map_until_stop_and_collect(f)? |
| 374 | .map_data(|new_inputs| { |
| 375 | let exprs = node.expressions(); |
| 376 | Ok(Extension { |
| 377 | node: node.with_exprs_and_inputs(exprs, new_inputs)?, |
| 378 | }) |
| 379 | }) |
| 380 | } |
| 381 | |
| 382 | /// This macro is used to determine continuation during combined transforming |
| 383 | /// traversals. |
no test coverage detected
searching dependent graphs…