Repository navigation
feat(query): set-membership predicates (#316, PR 2 of 3) - #743
Merged
Merged
Conversation
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TcpoiFyFeQQQELL872LfQF
…, none-in? (#316) Five BinOps over set values: filters and Boolean bindings, membership by Value's Ord (one NaN, -0.0 = 0.0, keyword != ref). A wrong operand shape is a type mismatch, so not-in? with a non-set drops the row. The names are built-in predicate sentinels. Grammar, GRAMMAR.md and a corpus fixture; prepared set binds tested in operand and value slots. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TcpoiFyFeQQQELL872LfQF
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TcpoiFyFeQQQELL872LfQF
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
This was referenced Oct 24, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Part of #316, PR 2 of 3 (set-membership predicates; spec §6, plan steps 13–16).
What
BinOp::{In, NotIn, AnyIn, AllIn, NoneIn}:in?/not-in?(scalar, set),any-in?/all-in?/none-in?(set, set). They work as filters and as Boolean bindings.Value'sOrd(spec §2), so NaN,-0.0/0.0and keyword ≠ ref need no special case.Err(())): a filter drops the row and a binding binds nothing. Sonot-in?with a non-set is never true.in? x #{}is false,not-in? x #{}true; with an empty first set,all-in?/none-in?are true andany-in?is false.PRS-065, as forcontains?. The five names are built-in predicate sentinels, soregister_predicaterefuses them.contains?stays string-only.binary_op,docs/GRAMMAR.mdis regenerated, and there is a corpus fixturequery_expr_set_predicates.edn.Value::Set). They are tested in an operand slot and a value slot, each re-executed with different sets.Gaps from the plan
#uuidis not an expression argument, in the parser or the grammar; that was already true. Ref operands are tested through stored attributes and bind slots instead.TOKENSare unchanged: the string predicates are not tokens either, so the verifier's cost stays the same.:order-byover a set column test waits for No working result-limiting/pagination mechanism for plain (non-recursive) :find queries #306's implementation, which has not merged. Whichever of the two lands second adds it.Tests
tests/set_predicates_test.rs(12 tests).eval_binopunit test.test-hooks.cargo test --all-featuresran on an idle machine: 1,780 passed, 0 failed.cargo clippy --all-features(native) and both wasm targets are clean.🤖 Generated with Claude Code
https://claude.ai/code/session_01TcpoiFyFeQQQELL872LfQF