| 161 | } |
| 162 | |
| 163 | void GroupDependencyAnalyzer::visitFunction(std::shared_ptr<binder::Expression> expr) { |
| 164 | auto& funcExpr = expr->constCast<ScalarFunctionExpression>(); |
| 165 | for (auto& child : expr->getChildren()) { |
| 166 | visit(child); |
| 167 | } |
| 168 | // For list lambda we need to flatten all dependent expressions in lambda function |
| 169 | // E.g. MATCH (a)->(b) RETURN list_filter(a.list, x -> x>b.age) |
| 170 | if (funcExpr.getFunction().isListLambda) { |
| 171 | auto lambdaFunctionAnalyzer = GroupDependencyAnalyzer(collectDependentExpr, schema); |
| 172 | lambdaFunctionAnalyzer.visit(funcExpr.getChild(1)); |
| 173 | requiredFlatGroups = lambdaFunctionAnalyzer.getDependentGroups(); |
| 174 | } |
| 175 | } |
| 176 | |
| 177 | void GroupDependencyAnalyzer::visitCase(std::shared_ptr<binder::Expression> expr) { |
| 178 | auto& caseExpression = expr->constCast<CaseExpression>(); |
nothing calls this directly
no test coverage detected