HomePhabricator

[ecash-lib] Add a bunch of helpers for `Script`

Description

[ecash-lib] Add a bunch of helpers for Script

Summary:
Add helper functions fromOps, ops, cutOutCodesep, isP2sh, p2sh, p2pkh, p2pkhSpend to Script.

Add ScriptOpIter, which is returned by Script.ops to iterate over the Ops of a Script.

Test Plan: npm run test && npm run build

Reviewers: bytesofman, #bitcoin_abc

Reviewed By: bytesofman, #bitcoin_abc

Differential Revision: https://reviews.bitcoinabc.org/D15952

Details

Provenance
tobias_ruckAuthored on Thu, Apr 11, 23:01
tobias_ruckPushed on Fri, Apr 12, 19:15
Reviewer
Restricted Project
Differential Revision
D15952: [ecash-lib] Add a bunch of helpers for `Script`
Parents
rABC42f15d7e8a7e: [explorer] Switch to new chronik
Branches
Unknown
Tags
Unknown