pub enum Const {
Int(IntType),
Float(FloatType),
Str(String),
}
Variants§
Implementations§
Source§impl Const
impl Const
pub fn add(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn sub(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn mul(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn div(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn idiv(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn mod_(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn pow(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn band(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn bor(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn bxor(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn shl(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn shr(self, other: Const) -> Result<Option<Const>, CompileError>
pub fn minus(&self) -> Result<Option<Const>, CompileError>
pub fn bnot(&self) -> Result<Option<Const>, CompileError>
Trait Implementations§
impl Eq for Const
impl StructuralPartialEq for Const
Auto Trait Implementations§
impl Freeze for Const
impl RefUnwindSafe for Const
impl Send for Const
impl Sync for Const
impl Unpin for Const
impl UnwindSafe for Const
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