pub struct RawVal(_);
Expand description

A 64-bit value encoding a bit-packed disjoint union between several different types (numbers, booleans, symbols, object handles, etc.)

RawVals divide up the space of 64 bits according to a 2-level tagging scheme. The first tag is a bit in the least-significant position, indicating whether the RawVal is a plain “u63” 63-bit unsigned integer, or some more-structured value with a second-level tag in the next most significant 3 bits. The 63-bit unsigned integer case can also be thought of as handling the complete range of non-negative signed 64-bit integers.

The remaining 3 bit tags are assigned to cases enumerated in Tag, of which 7 are defined and one is currently reserved.

Schematically, the bit-assignment for RawVal looks like this:

   0x_NNNN_NNNN_NNNN_NNNX  - u63, for any even X
   0x_0000_000N_NNNN_NNN1  - u32
   0x_0000_000N_NNNN_NNN3  - i32
   0x_NNNN_NNNN_NNNN_NNN5  - static: void, true, false, ...
   0x_IIII_IIII_TTTT_TTT7  - object: 32-bit index I, 28-bit type code T
   0x_NNNN_NNNN_NNNN_NNN9  - symbol: up to 10 6-bit identifier characters
   0x_NNNN_NNNN_NNNN_NNNb  - bitset: up to 60 bits
   0x_CCCC_CCCC_TTTT_TTTd  - status: 32-bit code C, 28-bit type code T
   0x_NNNN_NNNN_NNNN_NNNf  - reserved

Implementations§

source§

impl RawVal

source

pub const fn get_payload(self) -> u64

source

pub const fn from_payload(x: u64) -> RawVal

source

pub const fn shallow_eq(&self, other: &RawVal) -> bool

source

pub const fn is_u63(self) -> bool

source

pub const unsafe fn unchecked_as_u63(self) -> i64

source

pub const unsafe fn unchecked_from_u63(i: i64) -> RawVal

source

pub const fn get_tag(self) -> Tag

source

pub fn is<T>(self) -> boolwhere
T: RawValConvertible,

source

pub const fn from_void() -> RawVal

source

pub const fn from_bool(b: bool) -> RawVal

source

pub const fn from_other_static(st: ScStatic) -> RawVal

source

pub const fn from_u32(u: u32) -> RawVal

source

pub const fn from_i32(i: i32) -> RawVal

source

pub const fn is_i32_zero(self) -> bool

source

pub const fn is_u32_zero(self) -> bool

source

pub const fn is_void(self) -> bool

source

pub const fn is_true(self) -> bool

source

pub const fn is_false(self) -> bool

source§

impl RawVal

source

pub const I32_ZERO: RawVal = RawVal::from_i32(0)

source

pub const I32_POSITIVE_ONE: RawVal = RawVal::from_i32(1)

source

pub const I32_NEGATIVE_ONE: RawVal = RawVal::from_i32(-1)

source

pub const I32_MIN: RawVal = RawVal::from_i32(i32::MIN)

source

pub const I32_MAX: RawVal = RawVal::from_i32(i32::MAX)

source

pub const U32_ZERO: RawVal = RawVal::from_u32(0)

source

pub const U32_ONE: RawVal = RawVal::from_u32(1)

source

pub const U32_MIN: RawVal = RawVal::from_u32(u32::MIN)

source

pub const U32_MAX: RawVal = RawVal::from_u32(u32::MAX)

source

pub const VOID: RawVal = RawVal::from_other_static(ScStatic::Void)

source

pub const TRUE: RawVal = RawVal::from_bool(true)

source

pub const FALSE: RawVal = RawVal::from_bool(false)

Trait Implementations§

source§

impl AsMut<RawVal> for BitSet

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsMut<RawVal> for Object

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsMut<RawVal> for RawVal

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsMut<RawVal> for Static

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsMut<RawVal> for Status

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsMut<RawVal> for Symbol

source§

fn as_mut(&mut self) -> &mut RawVal

Converts this type into a mutable reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for BitSet

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for Object

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for RawVal

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for Static

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for Status

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl AsRef<RawVal> for Symbol

source§

fn as_ref(&self) -> &RawVal

Converts this type into a shared reference of the (usually inferred) input type.
source§

impl Clone for RawVal

source§

fn clone(&self) -> RawVal

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl Debug for RawVal

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl Default for RawVal

source§

fn default() -> RawVal

Returns the “default value” for a type. Read more
source§

impl From<&()> for RawVal

source§

fn from(_: &()) -> RawVal

Converts to this type from the input type.
source§

impl From<&ScStatus> for RawVal

source§

fn from(st: &ScStatus) -> RawVal

Converts to this type from the input type.
source§

impl From<&i32> for RawVal

source§

fn from(i: &i32) -> RawVal

Converts to this type from the input type.
source§

impl From<&u32> for RawVal

source§

fn from(u: &u32) -> RawVal

Converts to this type from the input type.
source§

impl From<()> for RawVal

source§

fn from(_: ()) -> RawVal

Converts to this type from the input type.
source§

impl From<BitSet> for RawVal

source§

fn from(b: BitSet) -> RawVal

Converts to this type from the input type.
source§

impl From<Object> for RawVal

source§

fn from(b: Object) -> RawVal

Converts to this type from the input type.
source§

impl From<RawVal> for DebugArg

source§

fn from(rv: RawVal) -> Self

Converts to this type from the input type.
source§

impl From<ScStatus> for RawVal

source§

fn from(st: ScStatus) -> RawVal

Converts to this type from the input type.
source§

impl From<Static> for RawVal

source§

fn from(b: Static) -> RawVal

Converts to this type from the input type.
source§

impl From<Status> for RawVal

source§

fn from(b: Status) -> RawVal

Converts to this type from the input type.
source§

impl From<Symbol> for RawVal

source§

fn from(b: Symbol) -> RawVal

Converts to this type from the input type.
source§

impl From<bool> for RawVal

source§

fn from(b: bool) -> RawVal

Converts to this type from the input type.
source§

impl From<i32> for RawVal

source§

fn from(i: i32) -> RawVal

Converts to this type from the input type.
source§

impl From<u32> for RawVal

source§

fn from(u: u32) -> RawVal

Converts to this type from the input type.
source§

impl FromValue for RawVal

source§

fn from_value(val: Value) -> Option<RawVal>

Create a value of type Self from a given Value. Read more
source§

impl TryFrom<&RawVal> for BitSet

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: &RawVal) -> Result<BitSet, <BitSet as TryFrom<&RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<&RawVal> for Object

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: &RawVal) -> Result<Object, <Object as TryFrom<&RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<&RawVal> for Static

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: &RawVal) -> Result<Static, <Static as TryFrom<&RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<&RawVal> for Status

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: &RawVal) -> Result<Status, <Status as TryFrom<&RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<&RawVal> for Symbol

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: &RawVal) -> Result<Symbol, <Symbol as TryFrom<&RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<RawVal> for BitSet

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: RawVal) -> Result<BitSet, <BitSet as TryFrom<RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<RawVal> for Object

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: RawVal) -> Result<Object, <Object as TryFrom<RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<RawVal> for Static

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: RawVal) -> Result<Static, <Static as TryFrom<RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<RawVal> for Status

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: RawVal) -> Result<Status, <Status as TryFrom<RawVal>>::Error>

Performs the conversion.
source§

impl TryFrom<RawVal> for Symbol

§

type Error = ConversionError

The type returned in the event of a conversion error.
source§

fn try_from(v: RawVal) -> Result<Symbol, <Symbol as TryFrom<RawVal>>::Error>

Performs the conversion.
source§

impl<E> TryFromVal<E, &[u8]> for RawValwhere
E: Env,

§

type Error = Status

source§

fn try_from_val(
env: &E,
v: &&[u8]
) -> Result<RawVal, <RawVal as TryFromVal<E, &[u8]>>::Error>

source§

impl<E> TryFromVal<E, &str> for RawValwhere
E: Env,

source§

impl<E, const N: usize> TryFromVal<E, [u8; N]> for RawValwhere
E: Env,

§

type Error = Status

source§

fn try_from_val(
env: &E,
v: &[u8; N]
) -> Result<RawVal, <RawVal as TryFromVal<E, [u8; N]>>::Error>

source§

impl<E> TryFromVal<E, ()> for RawValwhere
E: Env,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,
T8: TryIntoVal<E, RawVal>,
T9: TryIntoVal<E, RawVal>,
T10: TryIntoVal<E, RawVal>,
T11: TryIntoVal<E, RawVal>,
T12: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,
T8: TryIntoVal<E, RawVal>,
T9: TryIntoVal<E, RawVal>,
T10: TryIntoVal<E, RawVal>,
T11: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,
T8: TryIntoVal<E, RawVal>,
T9: TryIntoVal<E, RawVal>,
T10: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,
T8: TryIntoVal<E, RawVal>,
T9: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7, T8)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,
T8: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6, T7)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,
T7: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6> TryFromVal<E, (T0, T1, T2, T3, T4, T5, T6)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,
T6: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5> TryFromVal<E, (T0, T1, T2, T3, T4, T5)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,
T5: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4> TryFromVal<E, (T0, T1, T2, T3, T4)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,
T4: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3> TryFromVal<E, (T0, T1, T2, T3)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,
T3: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1, T2> TryFromVal<E, (T0, T1, T2)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,
T2: TryIntoVal<E, RawVal>,

source§

impl<E, T0, T1> TryFromVal<E, (T0, T1)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,
T1: TryIntoVal<E, RawVal>,

source§

impl<E, T0> TryFromVal<E, (T0,)> for RawValwhere
E: Env,
T0: TryIntoVal<E, RawVal>,

source§

impl<E> TryFromVal<E, BitSet> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, Object> for RawValwhere
E: Env,

source§

impl<E, T> TryFromVal<E, Option<T>> for RawValwhere
E: Env,
T: TryIntoVal<E, RawVal>,

§

type Error = <T as TryIntoVal<E, RawVal>>::Error

source§

fn try_from_val(
env: &E,
v: &Option<T>
) -> Result<RawVal, <RawVal as TryFromVal<E, Option<T>>>::Error>

source§

impl<E, const N: usize> TryFromVal<E, RawVal> for [u8; N]where
E: Env,

§

type Error = Status

source§

fn try_from_val(
env: &E,
val: &RawVal
) -> Result<[u8; N], <[u8; N] as TryFromVal<E, RawVal>>::Error>

source§

impl<E> TryFromVal<E, RawVal> for ()where
E: Env,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11, T12)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,
T8: TryFromVal<E, RawVal>,
T9: TryFromVal<E, RawVal>,
T10: TryFromVal<E, RawVal>,
T11: TryFromVal<E, RawVal>,
T12: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10, T11)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,
T8: TryFromVal<E, RawVal>,
T9: TryFromVal<E, RawVal>,
T10: TryFromVal<E, RawVal>,
T11: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9, T10)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,
T8: TryFromVal<E, RawVal>,
T9: TryFromVal<E, RawVal>,
T10: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8, T9> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7, T8, T9)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,
T8: TryFromVal<E, RawVal>,
T9: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7, T8> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7, T8)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,
T8: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6, T7> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6, T7)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,
T7: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5, T6> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5, T6)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,
T6: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4, T5> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4, T5)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,
T5: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3, T4> TryFromVal<E, RawVal> for (T0, T1, T2, T3, T4)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,
T4: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2, T3> TryFromVal<E, RawVal> for (T0, T1, T2, T3)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,
T3: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1, T2> TryFromVal<E, RawVal> for (T0, T1, T2)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,
T2: TryFromVal<E, RawVal>,

source§

impl<E, T0, T1> TryFromVal<E, RawVal> for (T0, T1)where
E: Env,
T0: TryFromVal<E, RawVal>,
T1: TryFromVal<E, RawVal>,

source§

impl<E, T0> TryFromVal<E, RawVal> for (T0,)where
E: Env,
T0: TryFromVal<E, RawVal>,

source§

impl<E> TryFromVal<E, RawVal> for BitSetwhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for Objectwhere
E: Env,

source§

impl<E, T> TryFromVal<E, RawVal> for Option<T>where
E: Env,
T: TryFromVal<E, RawVal>,

§

type Error = <T as TryFromVal<E, RawVal>>::Error

source§

fn try_from_val(
env: &E,
val: &RawVal
) -> Result<Option<T>, <Option<T> as TryFromVal<E, RawVal>>::Error>

source§

impl<E> TryFromVal<E, RawVal> for RawValwhere
E: Env,

source§

impl<E, T, R> TryFromVal<E, RawVal> for Result<T, R>where
E: Env,
T: TryFromVal<E, RawVal>,
R: TryFrom<Status>,

§

type Error = ConversionError

source§

fn try_from_val(
env: &E,
val: &RawVal
) -> Result<Result<T, R>, <Result<T, R> as TryFromVal<E, RawVal>>::Error>

source§

impl<E> TryFromVal<E, RawVal> for ScValwhere
E: Env,
ScObject: TryFromVal<E, Object>,

source§

impl<E> TryFromVal<E, RawVal> for Staticwhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for Statuswhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for Stringwhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for Symbolwhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for Vec<u8, Global>where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for boolwhere
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for i128where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for i32where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for i64where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for u128where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for u32where
E: Env,

source§

impl<E> TryFromVal<E, RawVal> for u64where
E: Env,

source§

impl<E, T, R> TryFromVal<E, Result<T, R>> for RawValwhere
E: Env,
RawVal: TryFromVal<E, T>,
Status: for<'a> TryFrom<&'a R>,

source§

impl<E> TryFromVal<E, ScVal> for RawValwhere
E: Env,
Object: TryFromVal<E, ScObject>,

source§

impl<E> TryFromVal<E, Static> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, Status> for RawValwhere
E: Env,

source§

impl<'a, E> TryFromVal<E, String> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, Symbol> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, Vec<u8, Global>> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, bool> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, i128> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, i32> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, i64> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, u128> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, u32> for RawValwhere
E: Env,

source§

impl<E> TryFromVal<E, u64> for RawValwhere
E: Env,

source§

impl Copy for RawVal

source§

impl Val for RawVal

Auto Trait Implementations§

Blanket Implementations§

source§

impl<T> Any for Twhere
T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for Twhere
T: ?Sized,

const: unstable · source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for Twhere
T: ?Sized,

const: unstable · source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T, C> Compare<&T> for Cwhere
C: Compare<T>,

§

type Error = <C as Compare<T>>::Error

source§

fn compare(&self, a: &&T, b: &&T) -> Result<Ordering, <C as Compare<&T>>::Error>

source§

impl<T, U, V, E, C> Compare<(T, U, V)> for Cwhere
C: Compare<T, Error = E, Error = E, Error = E> + Compare<U> + Compare<V>,

§

type Error = E

source§

fn compare(
&self,
a: &(T, U, V),
b: &(T, U, V)
) -> Result<Ordering, <C as Compare<(T, U, V)>>::Error>

source§

impl<T, U, E, C> Compare<(T, U)> for Cwhere
C: Compare<T, Error = E, Error = E> + Compare<U>,

§

type Error = E

source§

fn compare(
&self,
a: &(T, U),
b: &(T, U)
) -> Result<Ordering, <C as Compare<(T, U)>>::Error>

source§

impl<T, C> Compare<Box<T, Global>> for Cwhere
C: Compare<T>,

§

type Error = <C as Compare<T>>::Error

source§

fn compare(
&self,
a: &Box<T, Global>,
b: &Box<T, Global>
) -> Result<Ordering, <C as Compare<Box<T, Global>>>::Error>

source§

impl<T, C> Compare<Option<T>> for Cwhere
C: Compare<T>,

§

type Error = <C as Compare<T>>::Error

source§

fn compare(
&self,
a: &Option<T>,
b: &Option<T>
) -> Result<Ordering, <C as Compare<Option<T>>>::Error>

source§

impl<E> Compare<RawVal> for Ewhere
E: Env,

§

type Error = <E as EnvBase>::Error

source§

fn compare(
&self,
a: &RawVal,
b: &RawVal
) -> Result<Ordering, <E as Compare<RawVal>>::Error>

source§

impl<T, C> Compare<Rc<T>> for Cwhere
C: Compare<T>,

§

type Error = <C as Compare<T>>::Error

source§

fn compare(
&self,
a: &Rc<T>,
b: &Rc<T>
) -> Result<Ordering, <C as Compare<Rc<T>>>::Error>

source§

impl<T, C> Compare<Vec<T, Global>> for Cwhere
C: Compare<T>,

§

type Error = <C as Compare<T>>::Error

source§

fn compare(
&self,
a: &Vec<T, Global>,
b: &Vec<T, Global>
) -> Result<Ordering, <C as Compare<Vec<T, Global>>>::Error>

§

impl<T> Downcast for Twhere
T: Any,

§

fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>

Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.
§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>

Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be further downcast into Rc<ConcreteType> where ConcreteType implements Trait.
§

fn as_any(&self) -> &(dyn Any + 'static)

Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &Any’s vtable from &Trait’s.
§

fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)

Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot generate &mut Any’s vtable from &mut Trait’s.
§

impl<T> DowncastSync for Twhere
T: Any + Send + Sync,

§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Send + Sync + 'static>

Convert Arc<Trait> (where Trait: Downcast) to Arc<Any>. Arc<Any> can then be further downcast into Arc<ConcreteType> where ConcreteType implements Trait.
source§

impl<T> From<T> for T

const: unstable · source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for Twhere
U: From<T>,

const: unstable · source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> Same<T> for T

§

type Output = T

Should always be Self
source§

impl<T> ToOwned for Twhere
T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for Twhere
U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
const: unstable · source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for Twhere
U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
const: unstable · source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<E, T, U> TryIntoVal<E, T> for Uwhere
E: Env,
T: TryFromVal<E, U>,

§

type Error = <T as TryFromVal<E, U>>::Error

source§

fn try_into_val(&self, env: &E) -> Result<T, <U as TryIntoVal<E, T>>::Error>

§

impl<V, T> VZip<V> for Twhere
V: MultiLane<T>,

§

fn vzip(self) -> V