[query] Shift some pattern validation into query-parser #157

Open
opened 2020-08-06 16:55:54 +00:00 by gburd · 0 comments
gburd commented 2020-08-06 16:55:54 +00:00 (Migrated from github.com)

Some of the validation we do of or and not is intrinsic (can be done against the pattern alone), and some is only mildly extrinsic.

It would be nice if a query input like

[:find ?x :where [?x _ 5] (not-join [?zzzz] [?x _ 4])]

failed to parse entirely due to ?zzzz not being present inside the body of the not-join. This is what DataScript does, and it's nice.

Some of the validation we do of `or` and `not` is intrinsic (can be done against the pattern alone), and some is only mildly extrinsic. It would be nice if a query input like ```edn [:find ?x :where [?x _ 5] (not-join [?zzzz] [?x _ 4])] ``` failed to parse entirely due to `?zzzz` not being present inside the body of the `not-join`. This is what DataScript does, and it's nice.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: greg/mentat#157
No description provided.