tvix-store: have a specific type for blake3 digests

#268
Opened by flokli at 2023-05-11T14·56+00

It's 32 bytes, but writing it out explicitly in so many places is a bit annoying.

Define a

struct B3Digest([u8; 32]);

somewhere, and use it consistently.

We might also see if we can use this to generalize some of our error handling, when consuming proto structures (which can only represent Vec<u8>)

  1. https://rust-unofficial.github.io/patterns/patterns/behavioural/newtype.html

    flokli at 2023-05-15T18·53+00

  2. Landed in cl/8592 and cl/8605.

    flokli at 2023-05-29T14·18+00

  3. flokli closed this issue at 2023-05-29T14·18+00