Struct arithmetic_typing::arith::UnaryOpContext
source · pub struct UnaryOpContext<Prim: PrimitiveType> {
pub op: UnaryOp,
pub arg: Type<Prim>,
}
Expand description
Code spans related to a unary operation.
Used in TypeArithmetic::process_unary_op()
.
Fields§
§op: UnaryOp
Unary operation.
arg: Type<Prim>
Operation argument.
Trait Implementations§
source§impl<Prim: Clone + PrimitiveType> Clone for UnaryOpContext<Prim>
impl<Prim: Clone + PrimitiveType> Clone for UnaryOpContext<Prim>
source§fn clone(&self) -> UnaryOpContext<Prim>
fn clone(&self) -> UnaryOpContext<Prim>
Returns a copy 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<Prim: Debug + PrimitiveType> Debug for UnaryOpContext<Prim>
impl<Prim: Debug + PrimitiveType> Debug for UnaryOpContext<Prim>
source§impl<Prim: PrimitiveType> From<UnaryOpContext<Prim>> for ErrorContext<Prim>
impl<Prim: PrimitiveType> From<UnaryOpContext<Prim>> for ErrorContext<Prim>
source§fn from(value: UnaryOpContext<Prim>) -> Self
fn from(value: UnaryOpContext<Prim>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<Prim> Freeze for UnaryOpContext<Prim>where
Prim: Freeze,
impl<Prim> !RefUnwindSafe for UnaryOpContext<Prim>
impl<Prim> Send for UnaryOpContext<Prim>
impl<Prim> Sync for UnaryOpContext<Prim>
impl<Prim> Unpin for UnaryOpContext<Prim>where
Prim: Unpin,
impl<Prim> !UnwindSafe for UnaryOpContext<Prim>
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§default unsafe fn clone_to_uninit(&self, dst: *mut T)
default unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)