(plan: &LogicalPlan)
| 252 | } |
| 253 | |
| 254 | fn empty_child(plan: &LogicalPlan) -> Result<Option<LogicalPlan>> { |
| 255 | match plan.inputs()[..] { |
| 256 | [child] => match child { |
| 257 | LogicalPlan::EmptyRelation(empty) => { |
| 258 | if !empty.produce_one_row { |
| 259 | Ok(Some(LogicalPlan::EmptyRelation(EmptyRelation { |
| 260 | produce_one_row: false, |
| 261 | schema: Arc::clone(plan.schema()), |
| 262 | }))) |
| 263 | } else { |
| 264 | Ok(None) |
| 265 | } |
| 266 | } |
| 267 | _ => Ok(None), |
| 268 | }, |
| 269 | _ => plan_err!("plan just can have one child"), |
| 270 | } |
| 271 | } |
| 272 | |
| 273 | /// Builds a Projection that replaces one side of an outer join with NULL literals. |
| 274 | /// |
no test coverage detected
searching dependent graphs…