pub struct Value {
pub actual: MaybeNotInferred<ValueShape>,
pub ty: Type,
}Fields§
§actual: MaybeNotInferred<ValueShape>§ty: TypeImplementations§
Source§impl Value
impl Value
pub fn new_not_inferred() -> Self
pub fn new_not_inferred_of_ty(ty: Type) -> Self
Source§impl Value
impl Value
Sourcepub fn expect_type(self) -> Result<Type>
pub fn expect_type(self) -> Result<Type>
Get this value AS a type
pub fn expect_inferred(&self) -> Result<ValueShape>
Trait Implementations§
Source§impl From<ValueShape> for Value
impl From<ValueShape> for Value
Source§fn from(value: ValueShape) -> Self
fn from(value: ValueShape) -> Self
Converts to this type from the input type.
impl Eq for Value
impl StructuralPartialEq for Value
Auto Trait Implementations§
impl Freeze for Value
impl !RefUnwindSafe for Value
impl Send for Value
impl Sync for Value
impl Unpin for Value
impl !UnwindSafe for Value
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