pub struct OwnedCellSlice(/* private fields */);Expand description
A wrapper around CellSliceParts extending its lifetime.
Implementations§
Source§impl OwnedCellSlice
impl OwnedCellSlice
pub fn new_allow_exotic(cell: Cell) -> OwnedCellSlice
pub fn apply(&self) -> CellSlice<'_>
pub fn range(&self) -> CellSliceRange
pub fn range_mut(&mut self) -> &mut CellSliceRange
pub fn cell(&self) -> &Cell
pub fn set_range(&mut self, range: CellSliceRange)
pub fn fits_into(&self, builder: &CellBuilder) -> bool
Trait Implementations§
Source§impl Clone for OwnedCellSlice
impl Clone for OwnedCellSlice
Source§fn clone(&self) -> OwnedCellSlice
fn clone(&self) -> OwnedCellSlice
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 OwnedCellSlice
impl Debug for OwnedCellSlice
Source§impl Default for OwnedCellSlice
impl Default for OwnedCellSlice
Source§fn default() -> OwnedCellSlice
fn default() -> OwnedCellSlice
Returns the “default value” for a type. Read more
Source§impl Display for OwnedCellSlice
impl Display for OwnedCellSlice
Source§impl From<(CellSliceRange, Cell)> for OwnedCellSlice
impl From<(CellSliceRange, Cell)> for OwnedCellSlice
Source§fn from(parts: (CellSliceRange, Cell)) -> OwnedCellSlice
fn from(parts: (CellSliceRange, Cell)) -> OwnedCellSlice
Converts to this type from the input type.
Source§impl IntoCode for OwnedCellSlice
impl IntoCode for OwnedCellSlice
Source§impl PartialEq<CellSlice<'_>> for OwnedCellSlice
impl PartialEq<CellSlice<'_>> for OwnedCellSlice
Source§impl SafeRcMakeMut for OwnedCellSlice
impl SafeRcMakeMut for OwnedCellSlice
fn rc_make_mut(rc: &mut Rc<OwnedCellSlice>) -> &mut OwnedCellSlice
Source§impl StackValue for OwnedCellSlice
impl StackValue for OwnedCellSlice
fn rc_into_dyn(self: Rc<OwnedCellSlice>) -> Rc<dyn StackValue>
fn raw_ty(&self) -> u8
fn store_as_stack_value( &self, builder: &mut CellBuilder, _: &dyn CellContext, ) -> Result<(), Error>
fn fmt_dump(&self, f: &mut Formatter<'_>) -> Result<(), Error>
fn as_cell_slice(&self) -> Option<&OwnedCellSlice>
fn rc_into_cell_slice( self: Rc<OwnedCellSlice>, ) -> Result<Rc<OwnedCellSlice>, Box<VmError>>
fn as_int(&self) -> Option<&BigInt>
fn try_as_int(&self) -> Result<&BigInt, Box<VmError>>
fn rc_into_int(self: Rc<Self>) -> Result<Rc<BigInt>, Box<VmError>>
fn as_cell(&self) -> Option<&Cell>
fn try_as_cell(&self) -> Result<&Cell, Box<VmError>>
fn rc_into_cell(self: Rc<Self>) -> Result<Rc<Cell>, Box<VmError>>
fn try_as_cell_slice(&self) -> Result<&OwnedCellSlice, Box<VmError>>
fn as_cell_builder(&self) -> Option<&CellBuilder>
fn try_as_cell_builder(&self) -> Result<&CellBuilder, Box<VmError>>
fn rc_into_cell_builder(self: Rc<Self>) -> Result<Rc<CellBuilder>, Box<VmError>>
fn as_cont(&self) -> Option<&(dyn Cont + 'static)>
fn try_as_cont(&self) -> Result<&(dyn Cont + 'static), Box<VmError>>
fn rc_into_cont(self: Rc<Self>) -> Result<Rc<dyn Cont>, Box<VmError>>
fn as_tuple(&self) -> Option<&[SafeRc<dyn StackValue>]>
fn try_as_tuple(&self) -> Result<&[SafeRc<dyn StackValue>], Box<VmError>>
fn rc_into_tuple( self: Rc<Self>, ) -> Result<Rc<Vec<SafeRc<dyn StackValue>>>, Box<VmError>>
Source§impl StackValue for OwnedCellSlice
impl StackValue for OwnedCellSlice
fn ty(&self) -> StackValueType
fn is_equal(&self, other: &dyn StackValue) -> bool
fn fmt_dump(&self, f: &mut Formatter<'_>) -> Result
fn as_slice(&self) -> Result<CellSlice<'_>>
fn rc_into_cell_slice(self: Rc<Self>) -> Result<Rc<OwnedCellSlice>>
fn as_null(&self) -> Result<&()>
fn as_nan(&self) -> Result<&NaN>
fn as_int(&self) -> Result<&BigInt>
fn as_cell(&self) -> Result<&Cell>
fn as_builder(&self) -> Result<&CellBuilder>
fn as_string(&self) -> Result<&str>
fn as_bytes(&self) -> Result<&[u8]>
fn as_tuple(&self) -> Result<&StackTuple>
fn as_cont(&self) -> Result<&dyn FiftCont>
fn as_word_list(&self) -> Result<&WordList>
fn as_box(&self) -> Result<&SharedBox>
fn as_atom(&self) -> Result<&Atom>
fn as_hashmap(&self) -> Result<&HashMapTreeNode>
fn as_vm_cont(&self) -> Result<&RcCont>
fn rc_into_null(self: Rc<Self>) -> Result<Rc<()>>
fn rc_into_nan(self: Rc<Self>) -> Result<Rc<NaN>>
fn rc_into_int(self: Rc<Self>) -> Result<Rc<BigInt>>
fn rc_into_cell(self: Rc<Self>) -> Result<Rc<Cell>>
fn rc_into_builder(self: Rc<Self>) -> Result<Rc<CellBuilder>>
fn rc_into_string(self: Rc<Self>) -> Result<Rc<String>>
fn rc_into_bytes(self: Rc<Self>) -> Result<Rc<Vec<u8>>>
fn rc_into_tuple(self: Rc<Self>) -> Result<Rc<StackTuple>>
fn rc_into_cont(self: Rc<Self>) -> Result<Rc<dyn FiftCont>>
fn rc_into_word_list(self: Rc<Self>) -> Result<Rc<WordList>>
fn rc_into_atom(self: Rc<Self>) -> Result<Rc<Atom>>
fn rc_into_hashmap(self: Rc<Self>) -> Result<Rc<HashMapTreeNode>>
fn rc_into_vm_cont(self: Rc<Self>) -> Result<Rc<RcCont>>
Source§impl StaticStackValue for OwnedCellSlice
impl StaticStackValue for OwnedCellSlice
type DynRef<'a> = &'a OwnedCellSlice
fn known_ty() -> StackValueType
fn from_dyn( value: Rc<dyn StackValue>, ) -> Result<Rc<OwnedCellSlice>, Box<VmError>>
fn from_dyn_ref( value: &(dyn StackValue + 'static), ) -> Result<<OwnedCellSlice as StaticStackValue>::DynRef<'_>, Box<VmError>>
Auto Trait Implementations§
impl Freeze for OwnedCellSlice
impl !RefUnwindSafe for OwnedCellSlice
impl Send for OwnedCellSlice
impl Sync for OwnedCellSlice
impl Unpin for OwnedCellSlice
impl UnsafeUnpin for OwnedCellSlice
impl !UnwindSafe for OwnedCellSlice
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