feat(bindings): set_hash / set_hash_extended for all set types#10
Merged
Conversation
2 tasks
98c8152 to
aa069b2
Compare
Adds the two MEOS hash scalars for intset/bigintset/floatset/textset/
dateset/tstzset:
- set_hash(<set>) -> UINTEGER (MEOS uint32 set_hash)
- set_hash_extended(<set>, BIGINT seed) -> UBIGINT (MEOS uint64
set_hash_extended; seed cast to uint64)
Implementation mirrors the existing memSize accessor: copy the blob
into a malloc'd Set, call MEOS, free. Registered in the per-set-type
loop in src/temporal/set.cpp next to memSize / numValues.
Activates the corresponding queries in test/sql/parity/001_set.test
(set_hash and set_hash_extended round-trips on dateset and tstzset).
This was referenced Apr 25, 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.
Summary
Adds the two MEOS hash scalars for all six set types (intset/bigintset/floatset/textset/dateset/tstzset):
set_hash(<set>) -> UINTEGER(MEOSuint32 set_hash)set_hash_extended(<set>, BIGINT seed) -> UBIGINT(MEOSuint64 set_hash_extended; seed cast touint64)Implementation mirrors the existing
memSizeaccessor pattern: copy the blob into a malloc'dSet, call MEOS, free. Registered in the per-set-type loop insrc/temporal/set.cppnext tomemSize/numValues.Parity file
Unwraps the
set_hashskip block — 8 queries now active (4set_hashequality / inequality round-trips on dateset and tstzset, plus 4set_hash_extendedequivalents).Test plan
TZ=UTC ./build/release/test/unittest "<proj>/test/*"locally: 747 assertions pass across 13 test cases, no regressions.Dependencies
Branched off main (post #7 merge). Independent of #8 / #9 — no rebase or stack required.
🤖 Generated with Claude Code