commit 23c984f83e3c629f3b8a7c1b123a7b298c394352
parent 64618b41596bf4ceeb4459ed9c13694677dd097b
Author: Jared Tobin <jared@jtobin.io>
Date: Sat, 18 Apr 2026 20:39:03 +0800
bench: remove orphan NFData instances for ppad-tx types
NFData instances for TxId, OutPoint, and Witness are now provided
by ppad-tx itself. Remove orphans from bench suites.
Diffstat:
3 files changed, 71 insertions(+), 17 deletions(-)
diff --git a/bench/Main.hs b/bench/Main.hs
@@ -84,11 +84,6 @@ instance NFData OutputType where
instance NFData Script where
rnf (Script bs) = rnf bs
-instance NFData Witness where
- rnf (Witness items) = rnf items
-
-instance NFData OutPoint where
- rnf (OutPoint t i) = rnf t `seq` rnf i
instance NFData Sequence where
rnf (Sequence x) = rnf x
@@ -96,9 +91,6 @@ instance NFData Sequence where
instance NFData Locktime where
rnf (Locktime x) = rnf x
-instance NFData TxId where
- rnf (TxId bs) = rnf bs
-
instance NFData ToSelfDelay where
rnf (ToSelfDelay x) = rnf x
diff --git a/bench/Weight.hs b/bench/Weight.hs
@@ -121,11 +121,6 @@ instance NFData OutputType where
instance NFData Script where
rnf (Script bs) = rnf bs
-instance NFData Witness where
- rnf (Witness items) = rnf items
-
-instance NFData OutPoint where
- rnf (OutPoint t i) = rnf t `seq` rnf i
instance NFData Sequence where
rnf (Sequence x) = rnf x
@@ -133,9 +128,6 @@ instance NFData Sequence where
instance NFData Locktime where
rnf (Locktime x) = rnf x
-instance NFData TxId where
- rnf (TxId bs) = rnf bs
-
instance NFData ToSelfDelay where
rnf (ToSelfDelay x) = rnf x
diff --git a/flake.lock b/flake.lock
@@ -136,6 +136,40 @@
"url": "git://git.ppad.tech/base16.git"
}
},
+ "ppad-base16_4": {
+ "inputs": {
+ "flake-utils": [
+ "ppad-tx",
+ "ppad-base16",
+ "ppad-nixpkgs",
+ "flake-utils"
+ ],
+ "nixpkgs": [
+ "ppad-tx",
+ "ppad-base16",
+ "ppad-nixpkgs",
+ "nixpkgs"
+ ],
+ "ppad-nixpkgs": [
+ "ppad-tx",
+ "ppad-nixpkgs"
+ ]
+ },
+ "locked": {
+ "lastModified": 1766934151,
+ "narHash": "sha256-BUFpuLfrGXE2xi3Wa9TYCEhhRhFp175Ghxnr0JRbG2I=",
+ "ref": "master",
+ "rev": "58dfb7922401a60d5de76825fcd5f6ecbcd7afe0",
+ "revCount": 26,
+ "type": "git",
+ "url": "git://git.ppad.tech/base16.git"
+ },
+ "original": {
+ "ref": "master",
+ "type": "git",
+ "url": "git://git.ppad.tech/base16.git"
+ }
+ },
"ppad-fixed": {
"inputs": {
"flake-utils": [
@@ -375,6 +409,41 @@
"url": "git://git.ppad.tech/sha512.git"
}
},
+ "ppad-tx": {
+ "inputs": {
+ "flake-utils": [
+ "ppad-tx",
+ "ppad-nixpkgs",
+ "flake-utils"
+ ],
+ "nixpkgs": [
+ "ppad-tx",
+ "ppad-nixpkgs",
+ "nixpkgs"
+ ],
+ "ppad-base16": "ppad-base16_4",
+ "ppad-nixpkgs": [
+ "ppad-nixpkgs"
+ ],
+ "ppad-sha256": [
+ "ppad-sha256"
+ ]
+ },
+ "locked": {
+ "lastModified": 1776515759,
+ "narHash": "sha256-yRHrY3d3tL8ZM1dWKPYvaz7H3YsPtM8vd2ZwJKL2/nQ=",
+ "ref": "master",
+ "rev": "6e22072caac8c1db991c2640fcb795afba8c294a",
+ "revCount": 20,
+ "type": "git",
+ "url": "git://git.ppad.tech/tx.git"
+ },
+ "original": {
+ "ref": "master",
+ "type": "git",
+ "url": "git://git.ppad.tech/tx.git"
+ }
+ },
"root": {
"inputs": {
"flake-utils": [
@@ -388,7 +457,8 @@
"ppad-nixpkgs": "ppad-nixpkgs",
"ppad-ripemd160": "ppad-ripemd160",
"ppad-secp256k1": "ppad-secp256k1",
- "ppad-sha256": "ppad-sha256"
+ "ppad-sha256": "ppad-sha256",
+ "ppad-tx": "ppad-tx"
}
},
"systems": {