#node #trie #key #hash #merkle-tree #hasher #generic

no-std subtrie

Merkle-Patricia Trie generic over key hasher and node encoding

1 unstable release

0.0.1 Oct 28, 2024

#83 in #hasher

Download history 184/week @ 2024-10-25 221/week @ 2024-11-01 63/week @ 2024-11-08 5/week @ 2024-11-15

74 downloads per month

Apache-2.0

495KB
11K SLoC

Build Status

Trie

A generic implementation of the Base-16 Modified Merkle Tree ("Trie") data structure, provided under the Apache2 license.

Trie Hash alone is able to be used in no_std builds by disabling its (default) std feature. Implementation is in subtrie crate.

Testing in reference-trie crate and trie-db-test.

In the spirit of all things Rust, this aims to be reliable, secure, and high performance.

Used in the Substrate project. If you use this crate and would your project listed here, please contact us.

Buidling &c.

Building is done through cargo, as you'd expect.

Building

cargo build --all

Testing

cargo test --all

Benchmarking

cargo bench --all

Building in no_std

cargo build --no-default-features

lib.rs:

Trie interface and implementation.

Dependencies

~0.1–9.5MB
~93K SLoC