[−][src]Enum stk::ValuePtr
An entry on the stack.
Variants
An empty value indicating nothing.
Bool(bool)
A boolean.
Char(char)
A character.
Integer(i64)
A number.
Float(f64)
A float.
String(Slot)
A String.
Array(Slot)
An array.
Object(Slot)
An object.
External(Slot)
An external value.
Type(Hash)
A type.
Fn(Hash)
A function pointer.
Implementations
impl ValuePtr
[src]
pub fn into_string(self, vm: &Vm) -> Result<Slot, StackError>
[src]
Try to coerce value reference into an array.
pub fn into_array(self, vm: &Vm) -> Result<Slot, StackError>
[src]
Try to coerce value reference into an array.
pub fn into_object(self, vm: &Vm) -> Result<Slot, StackError>
[src]
Try to coerce value reference into an object.
pub fn into_external(self, vm: &Vm) -> Result<Slot, StackError>
[src]
Try to coerce value reference into an external.
pub fn value_type(&self, vm: &Vm) -> Result<ValueType, StackError>
[src]
Get the type information for the current value.
pub fn type_info(&self, vm: &Vm) -> Result<ValueTypeInfo, StackError>
[src]
Get the type information for the current value.
Trait Implementations
impl Clone for ValuePtr
[src]
impl Copy for ValuePtr
[src]
impl Debug for ValuePtr
[src]
impl Default for ValuePtr
[src]
impl<'de> Deserialize<'de> for ValuePtr
[src]
Deserialize implementation for value pointers.
Warning: This only works if a Vm
is accessible through tls, like by
being set up with tls::inject_vm or tls::InjectVm.
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error> where
D: Deserializer<'de>,
[src]
D: Deserializer<'de>,
impl FromValue for ValuePtr
[src]
fn from_value(value: ValuePtr, _: &mut Vm) -> Result<Self, StackError>
[src]
impl PartialEq<ValuePtr> for ValuePtr
[src]
impl Serialize for ValuePtr
[src]
Serialize implementation for value pointers.
Warning: This only works if a Vm
is accessible through tls, like by
being set up with tls::inject_vm or tls::InjectVm.
impl StructuralPartialEq for ValuePtr
[src]
impl ToValue for ValuePtr
[src]
Auto Trait Implementations
impl RefUnwindSafe for ValuePtr
impl Send for ValuePtr
impl Sync for ValuePtr
impl Unpin for ValuePtr
impl UnwindSafe for ValuePtr
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,