Skip to content

feat(traits): add Gamma, Pair, and ConstCoded bit serde structs#169

Open
zommiommy wants to merge 1 commit intomainfrom
feat/bit-serde-codes
Open

feat(traits): add Gamma, Pair, and ConstCoded bit serde structs#169
zommiommy wants to merge 1 commit intomainfrom
feat/bit-serde-codes

Conversation

@zommiommy
Copy link
Copy Markdown
Collaborator

@zommiommy zommiommy commented Apr 20, 2026

Adds new BitSerializer/BitDeserializer implementations for graph labels:

  • Gamma — encodes/decodes u64 via Elias γ codes
  • PrefixFree<const CODE: usize> — compile-time code selection via ConstCode dispatch (gamma, delta, zeta3, etc.), defaults to gamma
  • ZigZag<C> — maps i64 ↔ u64 via ToNat/ToInt bijection, wrapping any u64-based serializer (e.g. ZigZag(Gamma))
  • Pair<F, S> — composes two serializers to handle tuple (A, B) labels element-wise

@zommiommy zommiommy marked this pull request as draft April 20, 2026 11:46
@zommiommy zommiommy force-pushed the feat/bit-serde-codes branch 2 times, most recently from 768fc61 to a86ba38 Compare April 20, 2026 12:01
@zommiommy zommiommy marked this pull request as ready for review April 20, 2026 12:02
- Gamma: encodes/decodes u64 via Elias γ codes
- Pair<F, S>: composes two serializers for tuple (A, B) labels
- PrefixFree<CODE>: compile-time code selection via ConstCode dispatch
@zommiommy zommiommy force-pushed the feat/bit-serde-codes branch from a86ba38 to d49f179 Compare April 20, 2026 12:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant