Skip to content

Commit 117c0fa

Browse files
authored
fix: add std.crypo.hash compatible constants for ssz usage (#98)
2 parents 32e2bbe + 2902415 commit 117c0fa

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/ssz/poseidon_wrapper.zig

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,10 @@ pub fn PoseidonHasher(comptime Poseidon2Type: type) type {
5656
/// Options struct for compatibility with std.crypto.hash API
5757
pub const Options = struct {};
5858

59+
// std.crypto.hash-compatible constants
60+
pub const digest_length: usize = 32;
61+
pub const block_length: usize = 64;
62+
5963
/// Initialize a new hasher instance
6064
pub fn init(_: Options) Self {
6165
return .{

0 commit comments

Comments
 (0)