Conversation
|
Wow. This is amazing. I'll take a look through! |
|
Quick question while I'm reviewing. I'm unfamiliar with the latest CIP, so perhaps I'm not following. From the CIP, it seems that "path base" can never appear as an AST node itself: But this PR does add it as a concrete AST node. If there is common functionality or the need for a common base type (likely), then perhaps it could be a sub-type instead? Examples of this in the current codebase are |
|
Hi, Chris I maybe don`t understand what exactly sub-type is, but it doesn't look like a something that can contains useful fields. So I believe that this is not what we want. |
| named-path-clause = | ||
| < PATHPATTERN i:identifier EQUAL - p:pattern-path - | ||
| (WHERE e:expression | e:_null_) | ||
| > { $$ = named_path_predicate(i, p, e); } |
There was a problem hiding this comment.
Here we use named_path_predicate (almost the same as named_path) for named path patterns construction. So the node of type CYPHER_AST_NAMED_PATH may appear both as child of pattern and as child of query. Named path patterns and named paths are structurally identical but different in semantics. So should we create new concrete AST node for named-path-clause in this case?
|
Hi @cleishm! |
|
@gsvgit Ah - not intentional. Please feel free to re-open against the main branch! |
Hi @cleishm
The syntax for path patterns as described in this proposal (with this fix) is supported. This extension allows one to express RPQs and CFPQs (regular and context-free path queries) in Cypher.