pub enum SpkExpr<T: ExtParam> {
Const(T),
CurrInputSpk,
Input(IdxExpr),
Output(IdxExpr),
}
Expand description
Enum representing operations with transaction script pubkeys. Every variant of this enum pushes a witness program + 1 byte witness version on stack top. If the script pubkey is not a witness program. Push a sha256 hash of the script pubkey followed by -1 witness version This will abort when - Supplied index is out of bounds.
Variants§
Const(T)
A constant fixed script pubkey Pushes the witness program followed by witness version Pushes -1 if the legacy script pubkeys followed by sha256 hash of script pubkey
CurrInputSpk
Script pubkey under the current executing input
INSPECTCURRENTINPUTINDEX INPSECTINPUTSCRIPTPUBKEY
Input(IdxExpr)
Explicit asset at the given input index
i INPSECTINPUTSCRIPTPUBKEY
Output(IdxExpr)
Explicit asset at the given output index
i INPSECTOUTPUTSCRIPTPUBKEY
Implementations§
Trait Implementations§
Source§impl<T: ExtParam> ArgFromStr for SpkExpr<T>
impl<T: ExtParam> ArgFromStr for SpkExpr<T>
Source§impl<T: Ord + ExtParam> Ord for SpkExpr<T>
impl<T: Ord + ExtParam> Ord for SpkExpr<T>
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<T: PartialOrd + ExtParam> PartialOrd for SpkExpr<T>
impl<T: PartialOrd + ExtParam> PartialOrd for SpkExpr<T>
impl<T: Eq + ExtParam> Eq for SpkExpr<T>
impl<T: ExtParam> StructuralPartialEq for SpkExpr<T>
Auto Trait Implementations§
impl<T> Freeze for SpkExpr<T>where
T: Freeze,
impl<T> RefUnwindSafe for SpkExpr<T>where
T: RefUnwindSafe,
impl<T> Send for SpkExpr<T>where
T: Send,
impl<T> Sync for SpkExpr<T>where
T: Sync,
impl<T> Unpin for SpkExpr<T>where
T: Unpin,
impl<T> UnwindSafe for SpkExpr<T>where
T: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more