Enum rant::RantNumber
source · [−]Expand description
Represents a dynamically-typed Rant number.
Implements TryFromRant
and can therefore be used on native functions to accept any number type (int
or float
),
while preserving the original type.
Variants
Int(i64)
Rant int
value.
Float(f64)
Rant float
value.
Trait Implementations
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
This method tests for !=
.
This method returns an ordering between self
and other
values if one exists. Read more
This method tests less than (for self
and other
) and is used by the <
operator. Read more
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
Convert from a RantValue
.
Returns true
if the type can be used to represent an optional Rant parameter in native functions; otherwise, false
.
Auto Trait Implementations
impl RefUnwindSafe for RantNumber
impl Send for RantNumber
impl Sync for RantNumber
impl Unpin for RantNumber
impl UnwindSafe for RantNumber
Blanket Implementations
Mutably borrows from an owned value. Read more