Function std::inputs::input_predicate
pub fn input_predicate(index: u64) -> Option<Bytes>
Expand description
Gets the predicate from the input at index
.
Arguments
index
: [u64] - The index of the input to check.
Returns
- [Option] - The predicate bytecode of the input at
index
, if the input’s type isInput::Coin
orInput::Message
.
Examples
use std::inputs::input_predicate;
fn foo() {
let input_predicate = input_predicate(0).unwrap();
assert(input_predicate.len() != 0);
}