Add referenced aliases from MATCH clause - inline filtered and explicit WHERE filter.
| 126 | |
| 127 | // Add referenced aliases from MATCH clause - inline filtered and explicit WHERE filter. |
| 128 | static void _AST_MapMatchClauseReferences(AST *ast, const cypher_astnode_t *match_clause) { |
| 129 | // Inline filters. |
| 130 | const cypher_astnode_t *pattern = cypher_ast_match_get_pattern(match_clause); |
| 131 | uint path_count = cypher_ast_pattern_npaths(pattern); |
| 132 | for(uint i = 0; i < path_count; i++) { |
| 133 | const cypher_astnode_t *path = cypher_ast_pattern_get_path(pattern, i); |
| 134 | bool force_mapping = _shouldForceMapping(path); |
| 135 | _AST_MapReferencedEntitiesInPath(ast, path, force_mapping); |
| 136 | } |
| 137 | |
| 138 | // Where clause. |
| 139 | const cypher_astnode_t *predicate = cypher_ast_match_get_predicate(match_clause); |
| 140 | if(predicate) _AST_MapExpression(ast, predicate); |
| 141 | } |
| 142 | |
| 143 | // Add referenced aliases from CREATE clause. |
| 144 | static void _AST_MapCreateClauseReferences(AST *ast, const cypher_astnode_t *create_clause) { |
no test coverage detected