feat: add MerklePath
This commit is contained in:
parent
1cdd1d75fa
commit
70927645e7
1 changed files with 8 additions and 0 deletions
|
@ -722,6 +722,14 @@ instance FromJSON OrchardAction where
|
|||
a <- obj .: "spendAuthSig"
|
||||
pure $ OrchardAction n r c ephKey encText outText cval a
|
||||
|
||||
data MerklePath = MerklePath
|
||||
{ mp_position :: !Int64
|
||||
, mp_path :: ![HexString]
|
||||
} deriving stock (Eq, Prelude.Show, GHC.Generic)
|
||||
deriving anyclass (SOP.Generic, SOP.HasDatatypeInfo)
|
||||
deriving anyclass (Data.Structured.Show)
|
||||
deriving (BorshSize, ToBorsh, FromBorsh) via AsStruct MerklePath
|
||||
|
||||
-- | Type for a Orchard note commitment tree
|
||||
newtype OrchardCommitmentTree = OrchardCommitmentTree
|
||||
{ orchTree :: HexString
|
||||
|
|
Loading…
Reference in a new issue