pub struct ScriptStack { /* private fields */ }Expand description
Minimal stack abstraction used by the interpreter.
Implementations§
Source§impl ScriptStack
impl ScriptStack
Sourcepub fn from_items(items: Vec<Vec<u8>>) -> Result<Self, ScriptError>
pub fn from_items(items: Vec<Vec<u8>>) -> Result<Self, ScriptError>
Builds a stack from raw items after enforcing script-element limits.
Sourcepub fn push(&mut self, data: Vec<u8>) -> Result<(), ScriptError>
pub fn push(&mut self, data: Vec<u8>) -> Result<(), ScriptError>
Pushes a raw stack element after enforcing the script-element limit.
Sourcepub fn push_bool(&mut self, value: bool) -> Result<(), ScriptError>
pub fn push_bool(&mut self, value: bool) -> Result<(), ScriptError>
Pushes the canonical boolean stack encoding.
Trait Implementations§
Source§impl Clone for ScriptStack
impl Clone for ScriptStack
Source§fn clone(&self) -> ScriptStack
fn clone(&self) -> ScriptStack
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ScriptStack
impl Debug for ScriptStack
Source§impl Default for ScriptStack
impl Default for ScriptStack
Source§fn default() -> ScriptStack
fn default() -> ScriptStack
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for ScriptStack
impl RefUnwindSafe for ScriptStack
impl Send for ScriptStack
impl Sync for ScriptStack
impl Unpin for ScriptStack
impl UnsafeUnpin for ScriptStack
impl UnwindSafe for ScriptStack
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