Expand description
§miniscript-core-sys
FFI bindings to Bitcoin Core’s miniscript implementation.
This crate provides low-level bindings for cross-verification between Bitcoin Core’s C++ miniscript and other implementations like rust-miniscript.
§Example
use miniscript_core_sys::{Miniscript, Context};
let ms = Miniscript::from_str("and_v(v:pk(A),pk(B))", Context::Wsh)
.expect("valid miniscript");
assert!(ms.is_valid());
println!("Type: {}", ms.get_type().unwrap());
println!("String: {}", ms.to_string().unwrap());Structs§
- Error
- Error type for miniscript operations.
- Miniscript
- A parsed miniscript node.
- Miniscript
Node - Opaque handle to a parsed miniscript node
- Miniscript
Result - Result structure for miniscript operations
Enums§
- Context
- Script context for miniscript parsing.
- Miniscript
Context - Script context for miniscript parsing
Functions§
- miniscript_
free_ ⚠string - Free a string returned by miniscript functions.
- miniscript_
from_ ⚠string - Parse a miniscript string into a node.
- miniscript_
get_ ⚠type - Get the type properties of a miniscript node as a string.
- miniscript_
is_ ⚠sane - Check if a miniscript is sane.
- miniscript_
is_ ⚠valid - Check if a miniscript is valid (type-checks correctly).
- miniscript_
max_ ⚠satisfaction_ size - Get the maximum witness size for satisfying this miniscript.
- miniscript_
node_ ⚠free - Free a miniscript node.
- miniscript_
to_ ⚠string - Convert a miniscript node back to its string representation.
- miniscript_
version ⚠ - Get the library version string.
- version
- Get the library version string.