packages feed

mssmt-0.1.0: lib/Data/MSSMT.hs

{-# OPTIONS_HADDOCK prune #-}

-- |
-- Module: Data.MSSMT
-- Copyright: (c) 2026 Jared Tobin
-- License: MIT
-- Maintainer: Jared Tobin <jared@jtobin.io>
--
-- High-performance, in-memory merkle-sum sparse merkle trees (MS-SMTs).
--
-- An MS-SMT has 2^256 leaves, addressed by 256-bit keys. Each leaf
-- holds a value and a sum, and each branch commits to its children
-- and to the sum of their sums. Branches can commit to their children
-- in one of two ways, each with its own tree type:
--
-- * "Data.MSSMT.Split": each branch commits to the hash and sum of
--   each of its children. This is the default, re-exported here.
--
-- * "Data.MSSMT.Aggregate": each branch commits to its children's
--   hashes and the sum of their sums, as in Taproot Assets.

module Data.MSSMT (
    module Data.MSSMT.Split
  ) where

import Data.MSSMT.Split
import Prelude hiding (lookup)