bolt5

On-chain transaction handling for Lightning (docs.ppad.tech/bolt5).
git clone git://git.ppad.tech/bolt5.git
Log | Files | Refs | README | LICENSE

commit 334038e405c3cb319ebee293c2ef8e98cc19d241
parent 00417b6d4c0b7510d913bf313b45202a0f5d9bad
Author: Jared Tobin <jared@jtobin.io>
Date:   Sat, 10 Oct 2026 13:12:39 +0400

bench: drop NFData instances now provided by bolt1

Satoshi, MilliSatoshi, Point and PaymentHash have NFData instances in
ppad-bolt1, and bolt3 no longer exports the Pubkey constructor, so
force a Pubkey via unPubkey.

Diffstat:
Mbench/Main.hs | 14+-------------
Mbench/Weight.hs | 8+-------
2 files changed, 2 insertions(+), 20 deletions(-)

diff --git a/bench/Main.hs b/bench/Main.hs @@ -15,20 +15,11 @@ import qualified Lightning.Protocol.BOLT5 as B5 -- NFData orphan instances for criterion ----------------------------- -instance NFData Satoshi where - rnf (Satoshi x) = rnf x - -instance NFData MilliSatoshi where - rnf (MilliSatoshi x) = rnf x - instance NFData Script where rnf (Script bs) = rnf bs instance NFData Pubkey where - rnf (Pubkey x) = rnf x - -instance NFData Point where - rnf (Point x) = rnf x + rnf pk = rnf (unPubkey pk) instance NFData RevocationPubkey where rnf (RevocationPubkey x) = rnf x @@ -45,9 +36,6 @@ instance NFData FeeratePerKw where instance NFData ToSelfDelay where rnf (ToSelfDelay x) = rnf x -instance NFData PaymentHash where - rnf (PaymentHash x) = rnf x - instance NFData CltvExpiry where rnf (CltvExpiry x) = rnf x diff --git a/bench/Weight.hs b/bench/Weight.hs @@ -16,17 +16,11 @@ import Weigh -- NFData orphan instances for weigh --------------------------------- -instance NFData Satoshi where - rnf (Satoshi x) = rnf x - instance NFData Script where rnf (Script bs) = rnf bs instance NFData Pubkey where - rnf (Pubkey x) = rnf x - -instance NFData Point where - rnf (Point x) = rnf x + rnf pk = rnf (unPubkey pk) instance NFData RevocationPubkey where rnf (RevocationPubkey x) = rnf x