Return a vector of references to the subtrees of this expression in post-visit order (the last element is `&self`).
(&self)
| 2349 | /// Return a vector of references to the subtrees of this expression |
| 2350 | /// in post-visit order (the last element is `&self`). |
| 2351 | pub fn post_order_vec(&self) -> Vec<&Self> { |
| 2352 | let mut stack = vec![self]; |
| 2353 | let mut result = vec![]; |
| 2354 | while let Some(expr) = stack.pop() { |
| 2355 | result.push(expr); |
| 2356 | stack.extend(expr.children()); |
| 2357 | } |
| 2358 | result.reverse(); |
| 2359 | result |
| 2360 | } |
| 2361 | } |
| 2362 | |
| 2363 | impl VisitChildren<Self> for MirRelationExpr { |
no test coverage detected