| 139 | } |
| 140 | |
| 141 | bool isCall(const TypedExprPtr& expr, const std::string& name) { |
| 142 | if (auto call = std::dynamic_pointer_cast<const core::CallTypedExpr>(expr)) { |
| 143 | return call->name() == name; |
| 144 | } |
| 145 | return false; |
| 146 | } |
| 147 | |
| 148 | // Recursively flattens nested ANDs, ORs or eligible callable expressions into a |
| 149 | // vector of their inputs. Recursive flattening ceases exploring an input branch |