Struct ramp::int::Int [−][src]
pub struct Int { /* fields omitted */ }
An arbitrary-precision signed integer.
This type grows to the size it needs to in order to store the result of any operation.
Creation
An Int
can be constructed in a number of ways:
-
Int::zero
andInt::one
construct a zero- and one-valuedInt
respectively. -
Int::from
will convert from any primitive integer type to anInt
of the same valuelet four = Int::from(4);
-
Int::from_str
(orstr::parse
) will attempt to convert from a string to anInt
let i = Int::from_str("123456789").unwrap();
Output
Int
supports all the formatting traits, allowing it to be used just like a regular integer
when used in format!
and similar macros. Int
also supports conversion to primitive integer
types, truncating if the Int
cannot fit into the target type. Conversion to primtive integers
is done with the From
trait:
let big_i = Int::from(123456789); let i = i32::from(&big_i); assert_eq!(123456789, i);
Usage
Int
has a number of operator overloads to make working with them as painless as possible.
The most basic usage is simply a + b
or similar. Assuming a
and b
are of type Int
, this
operation will consume both operands, reusing the storage from one of them. If you do not wish
your operands to be moved, one or both of them can be references: &a + &b
works as well, but
requires an entire new Int
to be allocated for the return value.
There are also a overloads for a small number of primitive integer types, namely i32
and
usize
. While automatic type widening isn't done in Rust in general, many operations are much
more efficient when working with a single integer. This means you can do a + 1
knowing that it
will be performed as efficiently as possible. Comparison with these integer types is also
possible, allowing checks for small constant values to be done easily:
let big_i = Int::from(123456789); assert!(big_i == 123456789);
Semantics
Addition, subtraction and multiplication follow the expected rules for integers. Division of two
integers, N / D
is defined as producing two values: a quotient, Q
, and a remainder, R
,
such that the following equation holds: N = Q*D + R
. The division operator itself returns Q
while the remainder/modulo operator returns R
. The sign of R
is the same as the sign of Q
.
The "bit-shift" operations are defined as being multiplication and division by a power-of-two for shift-left and shift-right respectively. The sign of the number is unaffected.
The remaining bitwise operands act as if the numbers are stored in two's complement format and as if the two inputs have the same number of bits.
Methods
impl Int
[src]
impl Int
pub fn zero() -> Int
[src]
pub fn zero() -> Int
Creates the Int
that represents zero.
pub fn one() -> Int
[src]
pub fn one() -> Int
Creates the Int
that represents one.
pub fn from_single_limb(limb: Limb) -> Int
[src]
pub fn from_single_limb(limb: Limb) -> Int
Creates an Int
from a single Limb
pub fn sign(&self) -> i32
[src]
pub fn sign(&self) -> i32
Returns the sign of this Int
as either -1, 0 or 1 depending on whether it is negative,
zero, or positive, respectively.
pub fn abs(self) -> Int
[src]
pub fn abs(self) -> Int
Consumes this Int
and returns its absolute value.
pub fn to_single_limb(&self) -> Limb
[src]
pub fn to_single_limb(&self) -> Limb
Returns the least-significant Limb
of this Int
.
pub fn abs_cmp(&self, other: &Int) -> Ordering
[src]
pub fn abs_cmp(&self, other: &Int) -> Ordering
Compares the absolute value of this Int
with the absolute value of another.
pub fn abs_eq(&self, other: &Int) -> bool
[src]
pub fn abs_eq(&self, other: &Int) -> bool
Returns whether this Int
has the same absolute value as another.
pub fn abs_hash<H>(&self, state: &mut H) where
H: Hasher,
[src]
pub fn abs_hash<H>(&self, state: &mut H) where
H: Hasher,
Hashes the value without including the sign.
This is useful for when the sign is handled elsewhere and making a copy just to change the sign is wasteful.
pub fn shrink_to_fit(&mut self)
[src]
pub fn shrink_to_fit(&mut self)
Shrinks the allocated data for this Int
, attempting to remove excess capacity.
pub fn to_str_radix(&self, base: u8, upper: bool) -> String
[src]
pub fn to_str_radix(&self, base: u8, upper: bool) -> String
Creates a string containing the value of this Int
in base base
.
For bases greater than ten, if upper
is true, upper-case letters are used; otherwise,
lower-case letters are used.
Panics
Panics if base
is less than two or greater than 36.
pub fn write_radix<W: Write>(
&self,
w: &mut W,
base: u8,
upper: bool
) -> Result<()>
[src]
pub fn write_radix<W: Write>(
&self,
w: &mut W,
base: u8,
upper: bool
) -> Result<()>
Similar to to_str_radix
, writing to something that implements io::Write
instead.
pub fn from_str_radix(src: &str, base: u8) -> Result<Int, ParseIntError>
[src]
pub fn from_str_radix(src: &str, base: u8) -> Result<Int, ParseIntError>
Creates a new Int from the given string in base base
.
pub fn divmod(&self, other: &Int) -> (Int, Int)
[src]
pub fn divmod(&self, other: &Int) -> (Int, Int)
Divides this Int
by other
, returning the quotient q
and the remainder r
as (q, r)
.
This satisfies self = q * other + r
, ensuring that q
and r
have the same sign.
Panics
Panics if other
is zero.
pub fn pow(&self, exp: usize) -> Int
[src]
pub fn pow(&self, exp: usize) -> Int
Raises this Int
to the power of exp
. 0^0 = 1
.
pub fn pow_mod(&self, exp: &Int, modulus: &Int) -> Int
[src]
pub fn pow_mod(&self, exp: &Int, modulus: &Int) -> Int
Raises this Int
to the power exp
, all modulo modulus
. 0^0 mod m = 1 mod m
Panics
Panics if exp
is negative or modulus
is zero.
pub fn square(&self) -> Int
[src]
pub fn square(&self) -> Int
Squares this Int
.
pub fn dsquare(self) -> Int
[src]
pub fn dsquare(self) -> Int
Consumes this Int
and returns its square.
TODO: Is there a more idiomatic way of doing this?
pub fn sqrt_rem(self) -> Option<(Int, Int)>
[src]
pub fn sqrt_rem(self) -> Option<(Int, Int)>
Computes the nearest square root s
of this number and its remainder r
as
Some((s, r))
, or None
if this Int
is negative.
s
and r
are both positive and satisfy self = s * s + r
.
pub fn negate(&mut self)
[src]
pub fn negate(&mut self)
Negates this Int
in place.
pub fn is_even(&self) -> bool
[src]
pub fn is_even(&self) -> bool
Returns whether this Int
is even.
pub fn trailing_zeros(&self) -> u32
[src]
pub fn trailing_zeros(&self) -> u32
Returns the number of trailing zero bits for this Int
, or zero if this Int
is zero.
pub fn count_ones(&self) -> usize
[src]
pub fn count_ones(&self) -> usize
Returns the number of trailing one bits (i.e. the population count) for this Int
If this number is negative, it has infinitely many ones (in two's complement). Therefore,
this method returns usize::MAX
for negative numbers.
pub fn bit_length(&self) -> u32
[src]
pub fn bit_length(&self) -> u32
Returns the number of bits required to represent the absolute value of this Int
, i.e.,
floor(log2(abs(self))) + 1
.
Returns one if this number is zero.
pub fn bit(&self, bit: u32) -> bool
[src]
pub fn bit(&self, bit: u32) -> bool
Returns the value of the bit
th bit in this Int
, as if it were represented in two's
complement.
pub fn set_bit(&mut self, bit: u32, bit_val: bool)
[src]
pub fn set_bit(&mut self, bit: u32, bit_val: bool)
Sets the bit
th bit of this number to bit_val
, treating negative numbers as if they're
stored in two's complement.
pub fn gcd(&self, other: &Int) -> Int
[src]
pub fn gcd(&self, other: &Int) -> Int
Computes the greates common divisor (GCD) of this Int
and other
.
The result is always positive.
pub fn lcm(&self, other: &Int) -> Int
[src]
pub fn lcm(&self, other: &Int) -> Int
Computes the lowest common multiple (LCM) of this Int
and other
.
pub fn to_f64(&self) -> f64
[src]
pub fn to_f64(&self) -> f64
Converts this Int
into an f64
.
This is not an exact conversion, because this Int
may be more precise than an f64
can
account for.
Trait Implementations
impl Clone for Int
[src]
impl Clone for Int
fn clone(&self) -> Int
[src]
fn clone(&self) -> Int
Returns a copy of the value. Read more
fn clone_from(&mut self, other: &Int)
[src]
fn clone_from(&mut self, other: &Int)
Performs copy-assignment from source
. Read more
impl Default for Int
[src]
impl Default for Int
impl Drop for Int
[src]
impl Drop for Int
impl PartialEq<Int> for Int
[src]
impl PartialEq<Int> for Int
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Limb> for Int
[src]
impl PartialEq<Limb> for Int
fn eq(&self, other: &Limb) -> bool
[src]
fn eq(&self, other: &Limb) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Int> for Limb
[src]
impl PartialEq<Int> for Limb
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl Eq for Int
[src]
impl Eq for Int
impl Ord for Int
[src]
impl Ord for Int
fn cmp(&self, other: &Int) -> Ordering
[src]
fn cmp(&self, other: &Int) -> Ordering
This method returns an Ordering
between self
and other
. Read more
fn max(self, other: Self) -> Self
1.21.0[src]
fn max(self, other: Self) -> Self
Compares and returns the maximum of two values. Read more
fn min(self, other: Self) -> Self
1.21.0[src]
fn min(self, other: Self) -> Self
Compares and returns the minimum of two values. Read more
impl PartialOrd<Int> for Int
[src]
impl PartialOrd<Int> for Int
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Limb> for Int
[src]
impl PartialOrd<Limb> for Int
fn partial_cmp(&self, other: &Limb) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Limb) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Int> for Limb
[src]
impl PartialOrd<Int> for Limb
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl Hash for Int
[src]
impl Hash for Int
fn hash<H>(&self, state: &mut H) where
H: Hasher,
[src]
fn hash<H>(&self, state: &mut H) where
H: Hasher,
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl AddAssign<Limb> for Int
[src]
impl AddAssign<Limb> for Int
fn add_assign(&mut self, other: Limb)
[src]
fn add_assign(&mut self, other: Limb)
Performs the +=
operation.
impl Add<Limb> for Int
[src]
impl Add<Limb> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Limb) -> Int
[src]
fn add(self, other: Limb) -> Int
Performs the +
operation.
impl<'a> AddAssign<&'a Int> for Int
[src]
impl<'a> AddAssign<&'a Int> for Int
fn add_assign(&mut self, other: &'a Int)
[src]
fn add_assign(&mut self, other: &'a Int)
Performs the +=
operation.
impl<'a> Add<&'a Int> for Int
[src]
impl<'a> Add<&'a Int> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Int
[src]
fn add(self, other: &'a Int) -> Int
Performs the +
operation.
impl<'a> Add<Int> for &'a Int
[src]
impl<'a> Add<Int> for &'a Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Int
[src]
fn add(self, other: Int) -> Int
Performs the +
operation.
impl Add<Int> for Int
[src]
impl Add<Int> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Int
[src]
fn add(self, other: Int) -> Int
Performs the +
operation.
impl AddAssign<Int> for Int
[src]
impl AddAssign<Int> for Int
fn add_assign(&mut self, other: Int)
[src]
fn add_assign(&mut self, other: Int)
Performs the +=
operation.
impl<'a, 'b> Add<&'a Int> for &'b Int
[src]
impl<'a, 'b> Add<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Int
[src]
fn add(self, other: &'a Int) -> Int
Performs the +
operation.
impl SubAssign<Limb> for Int
[src]
impl SubAssign<Limb> for Int
fn sub_assign(&mut self, other: Limb)
[src]
fn sub_assign(&mut self, other: Limb)
Performs the -=
operation.
impl Sub<Limb> for Int
[src]
impl Sub<Limb> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Limb) -> Int
[src]
fn sub(self, other: Limb) -> Int
Performs the -
operation.
impl<'a> SubAssign<&'a Int> for Int
[src]
impl<'a> SubAssign<&'a Int> for Int
fn sub_assign(&mut self, other: &'a Int)
[src]
fn sub_assign(&mut self, other: &'a Int)
Performs the -=
operation.
impl<'a> Sub<&'a Int> for Int
[src]
impl<'a> Sub<&'a Int> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: &'a Int) -> Int
[src]
fn sub(self, other: &'a Int) -> Int
Performs the -
operation.
impl<'a> Sub<Int> for &'a Int
[src]
impl<'a> Sub<Int> for &'a Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Int) -> Int
[src]
fn sub(self, other: Int) -> Int
Performs the -
operation.
impl Sub<Int> for Int
[src]
impl Sub<Int> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Int) -> Int
[src]
fn sub(self, other: Int) -> Int
Performs the -
operation.
impl SubAssign<Int> for Int
[src]
impl SubAssign<Int> for Int
fn sub_assign(&mut self, other: Int)
[src]
fn sub_assign(&mut self, other: Int)
Performs the -=
operation.
impl<'a, 'b> Sub<&'a Int> for &'b Int
[src]
impl<'a, 'b> Sub<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: &'a Int) -> Int
[src]
fn sub(self, other: &'a Int) -> Int
Performs the -
operation.
impl MulAssign<Limb> for Int
[src]
impl MulAssign<Limb> for Int
fn mul_assign(&mut self, other: Limb)
[src]
fn mul_assign(&mut self, other: Limb)
Performs the *=
operation.
impl Mul<Limb> for Int
[src]
impl Mul<Limb> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Limb) -> Int
[src]
fn mul(self, other: Limb) -> Int
Performs the *
operation.
impl<'a, 'b> Mul<&'a Int> for &'b Int
[src]
impl<'a, 'b> Mul<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Int
[src]
fn mul(self, other: &'a Int) -> Int
Performs the *
operation.
impl<'a> Mul<&'a Int> for Int
[src]
impl<'a> Mul<&'a Int> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Int
[src]
fn mul(self, other: &'a Int) -> Int
Performs the *
operation.
impl<'a> Mul<Int> for &'a Int
[src]
impl<'a> Mul<Int> for &'a Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Int
[src]
fn mul(self, other: Int) -> Int
Performs the *
operation.
impl Mul<Int> for Int
[src]
impl Mul<Int> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Int
[src]
fn mul(self, other: Int) -> Int
Performs the *
operation.
impl<'a> MulAssign<&'a Int> for Int
[src]
impl<'a> MulAssign<&'a Int> for Int
fn mul_assign(&mut self, other: &'a Int)
[src]
fn mul_assign(&mut self, other: &'a Int)
Performs the *=
operation.
impl MulAssign<Int> for Int
[src]
impl MulAssign<Int> for Int
fn mul_assign(&mut self, other: Int)
[src]
fn mul_assign(&mut self, other: Int)
Performs the *=
operation.
impl DivAssign<Limb> for Int
[src]
impl DivAssign<Limb> for Int
fn div_assign(&mut self, other: Limb)
[src]
fn div_assign(&mut self, other: Limb)
Performs the /=
operation.
impl Div<Limb> for Int
[src]
impl Div<Limb> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Limb) -> Int
[src]
fn div(self, other: Limb) -> Int
Performs the /
operation.
impl<'a, 'b> Div<&'a Int> for &'b Int
[src]
impl<'a, 'b> Div<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Int
[src]
fn div(self, other: &'a Int) -> Int
Performs the /
operation.
impl<'a> Div<&'a Int> for Int
[src]
impl<'a> Div<&'a Int> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Int
[src]
fn div(self, other: &'a Int) -> Int
Performs the /
operation.
impl<'a> Div<Int> for &'a Int
[src]
impl<'a> Div<Int> for &'a Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Int
[src]
fn div(self, other: Int) -> Int
Performs the /
operation.
impl Div<Int> for Int
[src]
impl Div<Int> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Int
[src]
fn div(self, other: Int) -> Int
Performs the /
operation.
impl<'a> DivAssign<&'a Int> for Int
[src]
impl<'a> DivAssign<&'a Int> for Int
fn div_assign(&mut self, other: &'a Int)
[src]
fn div_assign(&mut self, other: &'a Int)
Performs the /=
operation.
impl DivAssign<Int> for Int
[src]
impl DivAssign<Int> for Int
fn div_assign(&mut self, other: Int)
[src]
fn div_assign(&mut self, other: Int)
Performs the /=
operation.
impl Rem<Limb> for Int
[src]
impl Rem<Limb> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Limb) -> Int
[src]
fn rem(self, other: Limb) -> Int
Performs the %
operation.
impl RemAssign<Limb> for Int
[src]
impl RemAssign<Limb> for Int
fn rem_assign(&mut self, other: Limb)
[src]
fn rem_assign(&mut self, other: Limb)
Performs the %=
operation.
impl DivRem<Limb> for Int
[src]
impl DivRem<Limb> for Int
impl<'a, 'b> Rem<&'a Int> for &'b Int
[src]
impl<'a, 'b> Rem<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: &'a Int) -> Int
[src]
fn rem(self, other: &'a Int) -> Int
Performs the %
operation.
impl<'a> Rem<&'a Int> for Int
[src]
impl<'a> Rem<&'a Int> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: &'a Int) -> Int
[src]
fn rem(self, other: &'a Int) -> Int
Performs the %
operation.
impl<'a> Rem<Int> for &'a Int
[src]
impl<'a> Rem<Int> for &'a Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Int) -> Int
[src]
fn rem(self, other: Int) -> Int
Performs the %
operation.
impl Rem<Int> for Int
[src]
impl Rem<Int> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Int) -> Int
[src]
fn rem(self, other: Int) -> Int
Performs the %
operation.
impl<'a, 'b> DivRem<&'a Int> for &'b Int
[src]
impl<'a, 'b> DivRem<&'a Int> for &'b Int
impl RemAssign<Int> for Int
[src]
impl RemAssign<Int> for Int
fn rem_assign(&mut self, other: Int)
[src]
fn rem_assign(&mut self, other: Int)
Performs the %=
operation.
impl<'a> RemAssign<&'a Int> for Int
[src]
impl<'a> RemAssign<&'a Int> for Int
fn rem_assign(&mut self, other: &'a Int)
[src]
fn rem_assign(&mut self, other: &'a Int)
Performs the %=
operation.
impl Neg for Int
[src]
impl Neg for Int
type Output = Int
The resulting type after applying the -
operator.
fn neg(self) -> Int
[src]
fn neg(self) -> Int
Performs the unary -
operation.
impl<'a> Neg for &'a Int
[src]
impl<'a> Neg for &'a Int
type Output = Int
The resulting type after applying the -
operator.
fn neg(self) -> Int
[src]
fn neg(self) -> Int
Performs the unary -
operation.
impl ShlAssign<usize> for Int
[src]
impl ShlAssign<usize> for Int
fn shl_assign(&mut self, cnt: usize)
[src]
fn shl_assign(&mut self, cnt: usize)
Performs the <<=
operation.
impl<'a> Shl<usize> for &'a Int
[src]
impl<'a> Shl<usize> for &'a Int
type Output = Int
The resulting type after applying the <<
operator.
fn shl(self, cnt: usize) -> Int
[src]
fn shl(self, cnt: usize) -> Int
Performs the <<
operation.
impl Shl<usize> for Int
[src]
impl Shl<usize> for Int
type Output = Int
The resulting type after applying the <<
operator.
fn shl(self, other: usize) -> Int
[src]
fn shl(self, other: usize) -> Int
Performs the <<
operation.
impl ShrAssign<usize> for Int
[src]
impl ShrAssign<usize> for Int
fn shr_assign(&mut self, cnt: usize)
[src]
fn shr_assign(&mut self, cnt: usize)
Performs the >>=
operation.
impl<'a> Shr<usize> for &'a Int
[src]
impl<'a> Shr<usize> for &'a Int
type Output = Int
The resulting type after applying the >>
operator.
fn shr(self, other: usize) -> Int
[src]
fn shr(self, other: usize) -> Int
Performs the >>
operation.
impl Shr<usize> for Int
[src]
impl Shr<usize> for Int
type Output = Int
The resulting type after applying the >>
operator.
fn shr(self, other: usize) -> Int
[src]
fn shr(self, other: usize) -> Int
Performs the >>
operation.
impl<'a> BitAnd<Limb> for Int
[src]
impl<'a> BitAnd<Limb> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Limb) -> Int
[src]
fn bitand(self, other: Limb) -> Int
Performs the &
operation.
impl BitAndAssign<Limb> for Int
[src]
impl BitAndAssign<Limb> for Int
fn bitand_assign(&mut self, other: Limb)
[src]
fn bitand_assign(&mut self, other: Limb)
Performs the &=
operation.
impl<'a> BitAnd<&'a Int> for Int
[src]
impl<'a> BitAnd<&'a Int> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: &'a Int) -> Int
[src]
fn bitand(self, other: &'a Int) -> Int
Performs the &
operation.
impl<'a> BitAnd<Int> for &'a Int
[src]
impl<'a> BitAnd<Int> for &'a Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Int) -> Int
[src]
fn bitand(self, other: Int) -> Int
Performs the &
operation.
impl<'a, 'b> BitAnd<&'a Int> for &'b Int
[src]
impl<'a, 'b> BitAnd<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: &'a Int) -> Int
[src]
fn bitand(self, other: &'a Int) -> Int
Performs the &
operation.
impl BitAnd<Int> for Int
[src]
impl BitAnd<Int> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Int) -> Int
[src]
fn bitand(self, other: Int) -> Int
Performs the &
operation.
impl BitAndAssign<Int> for Int
[src]
impl BitAndAssign<Int> for Int
fn bitand_assign(&mut self, other: Int)
[src]
fn bitand_assign(&mut self, other: Int)
Performs the &=
operation.
impl<'a> BitAndAssign<&'a Int> for Int
[src]
impl<'a> BitAndAssign<&'a Int> for Int
fn bitand_assign(&mut self, other: &'a Int)
[src]
fn bitand_assign(&mut self, other: &'a Int)
Performs the &=
operation.
impl BitOr<Limb> for Int
[src]
impl BitOr<Limb> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Limb) -> Int
[src]
fn bitor(self, other: Limb) -> Int
Performs the |
operation.
impl BitOrAssign<Limb> for Int
[src]
impl BitOrAssign<Limb> for Int
fn bitor_assign(&mut self, other: Limb)
[src]
fn bitor_assign(&mut self, other: Limb)
Performs the |=
operation.
impl<'a> BitOr<&'a Int> for Int
[src]
impl<'a> BitOr<&'a Int> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: &'a Int) -> Int
[src]
fn bitor(self, other: &'a Int) -> Int
Performs the |
operation.
impl<'a> BitOr<Int> for &'a Int
[src]
impl<'a> BitOr<Int> for &'a Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Int) -> Int
[src]
fn bitor(self, other: Int) -> Int
Performs the |
operation.
impl<'a, 'b> BitOr<&'a Int> for &'b Int
[src]
impl<'a, 'b> BitOr<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: &'a Int) -> Int
[src]
fn bitor(self, other: &'a Int) -> Int
Performs the |
operation.
impl BitOr<Int> for Int
[src]
impl BitOr<Int> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Int) -> Int
[src]
fn bitor(self, other: Int) -> Int
Performs the |
operation.
impl BitOrAssign<Int> for Int
[src]
impl BitOrAssign<Int> for Int
fn bitor_assign(&mut self, other: Int)
[src]
fn bitor_assign(&mut self, other: Int)
Performs the |=
operation.
impl<'a> BitOrAssign<&'a Int> for Int
[src]
impl<'a> BitOrAssign<&'a Int> for Int
fn bitor_assign(&mut self, other: &'a Int)
[src]
fn bitor_assign(&mut self, other: &'a Int)
Performs the |=
operation.
impl<'a> BitXor<Limb> for Int
[src]
impl<'a> BitXor<Limb> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Limb) -> Int
[src]
fn bitxor(self, other: Limb) -> Int
Performs the ^
operation.
impl BitXorAssign<Limb> for Int
[src]
impl BitXorAssign<Limb> for Int
fn bitxor_assign(&mut self, other: Limb)
[src]
fn bitxor_assign(&mut self, other: Limb)
Performs the ^=
operation.
impl<'a> BitXor<&'a Int> for Int
[src]
impl<'a> BitXor<&'a Int> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: &'a Int) -> Int
[src]
fn bitxor(self, other: &'a Int) -> Int
Performs the ^
operation.
impl<'a> BitXor<Int> for &'a Int
[src]
impl<'a> BitXor<Int> for &'a Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Int) -> Int
[src]
fn bitxor(self, other: Int) -> Int
Performs the ^
operation.
impl<'a, 'b> BitXor<&'a Int> for &'b Int
[src]
impl<'a, 'b> BitXor<&'a Int> for &'b Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: &'a Int) -> Int
[src]
fn bitxor(self, other: &'a Int) -> Int
Performs the ^
operation.
impl BitXor<Int> for Int
[src]
impl BitXor<Int> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Int) -> Int
[src]
fn bitxor(self, other: Int) -> Int
Performs the ^
operation.
impl BitXorAssign<Int> for Int
[src]
impl BitXorAssign<Int> for Int
fn bitxor_assign(&mut self, other: Int)
[src]
fn bitxor_assign(&mut self, other: Int)
Performs the ^=
operation.
impl<'a> BitXorAssign<&'a Int> for Int
[src]
impl<'a> BitXorAssign<&'a Int> for Int
fn bitxor_assign(&mut self, other: &'a Int)
[src]
fn bitxor_assign(&mut self, other: &'a Int)
Performs the ^=
operation.
impl Add<i32> for Int
[src]
impl Add<i32> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: i32) -> Int
[src]
fn add(self, other: i32) -> Int
Performs the +
operation.
impl AddAssign<i32> for Int
[src]
impl AddAssign<i32> for Int
fn add_assign(&mut self, other: i32)
[src]
fn add_assign(&mut self, other: i32)
Performs the +=
operation.
impl Sub<i32> for Int
[src]
impl Sub<i32> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: i32) -> Int
[src]
fn sub(self, other: i32) -> Int
Performs the -
operation.
impl SubAssign<i32> for Int
[src]
impl SubAssign<i32> for Int
fn sub_assign(&mut self, other: i32)
[src]
fn sub_assign(&mut self, other: i32)
Performs the -=
operation.
impl Mul<i32> for Int
[src]
impl Mul<i32> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: i32) -> Int
[src]
fn mul(self, other: i32) -> Int
Performs the *
operation.
impl MulAssign<i32> for Int
[src]
impl MulAssign<i32> for Int
fn mul_assign(&mut self, other: i32)
[src]
fn mul_assign(&mut self, other: i32)
Performs the *=
operation.
impl DivAssign<i32> for Int
[src]
impl DivAssign<i32> for Int
fn div_assign(&mut self, other: i32)
[src]
fn div_assign(&mut self, other: i32)
Performs the /=
operation.
impl Div<i32> for Int
[src]
impl Div<i32> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: i32) -> Int
[src]
fn div(self, other: i32) -> Int
Performs the /
operation.
impl RemAssign<i32> for Int
[src]
impl RemAssign<i32> for Int
fn rem_assign(&mut self, other: i32)
[src]
fn rem_assign(&mut self, other: i32)
Performs the %=
operation.
impl Rem<i32> for Int
[src]
impl Rem<i32> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: i32) -> Int
[src]
fn rem(self, other: i32) -> Int
Performs the %
operation.
impl DivRem<i32> for Int
[src]
impl DivRem<i32> for Int
impl BitAndAssign<i32> for Int
[src]
impl BitAndAssign<i32> for Int
fn bitand_assign(&mut self, other: i32)
[src]
fn bitand_assign(&mut self, other: i32)
Performs the &=
operation.
impl BitOrAssign<i32> for Int
[src]
impl BitOrAssign<i32> for Int
fn bitor_assign(&mut self, other: i32)
[src]
fn bitor_assign(&mut self, other: i32)
Performs the |=
operation.
impl BitXorAssign<i32> for Int
[src]
impl BitXorAssign<i32> for Int
fn bitxor_assign(&mut self, other: i32)
[src]
fn bitxor_assign(&mut self, other: i32)
Performs the ^=
operation.
impl<'a> Add<i32> for &'a Int
[src]
impl<'a> Add<i32> for &'a Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: i32) -> Int
[src]
fn add(self, other: i32) -> Int
Performs the +
operation.
impl Add<Int> for i32
[src]
impl Add<Int> for i32
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Int
[src]
fn add(self, other: Int) -> Int
Performs the +
operation.
impl<'a> Add<&'a Int> for i32
[src]
impl<'a> Add<&'a Int> for i32
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Int
[src]
fn add(self, other: &'a Int) -> Int
Performs the +
operation.
impl<'a> Sub<i32> for &'a Int
[src]
impl<'a> Sub<i32> for &'a Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: i32) -> Int
[src]
fn sub(self, other: i32) -> Int
Performs the -
operation.
impl Sub<Int> for i32
[src]
impl Sub<Int> for i32
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Int) -> Int
[src]
fn sub(self, other: Int) -> Int
Performs the -
operation.
impl<'a> Sub<&'a Int> for i32
[src]
impl<'a> Sub<&'a Int> for i32
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: &'a Int) -> Int
[src]
fn sub(self, other: &'a Int) -> Int
Performs the -
operation.
impl<'a> Mul<i32> for &'a Int
[src]
impl<'a> Mul<i32> for &'a Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: i32) -> Int
[src]
fn mul(self, other: i32) -> Int
Performs the *
operation.
impl Mul<Int> for i32
[src]
impl Mul<Int> for i32
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Int
[src]
fn mul(self, other: Int) -> Int
Performs the *
operation.
impl<'a> Mul<&'a Int> for i32
[src]
impl<'a> Mul<&'a Int> for i32
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Int
[src]
fn mul(self, other: &'a Int) -> Int
Performs the *
operation.
impl<'a> Div<i32> for &'a Int
[src]
impl<'a> Div<i32> for &'a Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: i32) -> Int
[src]
fn div(self, other: i32) -> Int
Performs the /
operation.
impl Div<Int> for i32
[src]
impl Div<Int> for i32
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Int
[src]
fn div(self, other: Int) -> Int
Performs the /
operation.
impl<'a> Div<&'a Int> for i32
[src]
impl<'a> Div<&'a Int> for i32
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Int
[src]
fn div(self, other: &'a Int) -> Int
Performs the /
operation.
impl<'a> Rem<i32> for &'a Int
[src]
impl<'a> Rem<i32> for &'a Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: i32) -> Int
[src]
fn rem(self, other: i32) -> Int
Performs the %
operation.
impl Rem<Int> for i32
[src]
impl Rem<Int> for i32
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Int) -> Int
[src]
fn rem(self, other: Int) -> Int
Performs the %
operation.
impl<'a> Rem<&'a Int> for i32
[src]
impl<'a> Rem<&'a Int> for i32
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: &'a Int) -> Int
[src]
fn rem(self, other: &'a Int) -> Int
Performs the %
operation.
impl BitAnd<i32> for Int
[src]
impl BitAnd<i32> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: i32) -> Int
[src]
fn bitand(self, other: i32) -> Int
Performs the &
operation.
impl<'a> BitAnd<i32> for &'a Int
[src]
impl<'a> BitAnd<i32> for &'a Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: i32) -> Int
[src]
fn bitand(self, other: i32) -> Int
Performs the &
operation.
impl BitAnd<Int> for i32
[src]
impl BitAnd<Int> for i32
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Int) -> Int
[src]
fn bitand(self, other: Int) -> Int
Performs the &
operation.
impl<'a> BitAnd<&'a Int> for i32
[src]
impl<'a> BitAnd<&'a Int> for i32
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: &'a Int) -> Int
[src]
fn bitand(self, other: &'a Int) -> Int
Performs the &
operation.
impl BitOr<i32> for Int
[src]
impl BitOr<i32> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: i32) -> Int
[src]
fn bitor(self, other: i32) -> Int
Performs the |
operation.
impl<'a> BitOr<i32> for &'a Int
[src]
impl<'a> BitOr<i32> for &'a Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: i32) -> Int
[src]
fn bitor(self, other: i32) -> Int
Performs the |
operation.
impl BitOr<Int> for i32
[src]
impl BitOr<Int> for i32
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Int) -> Int
[src]
fn bitor(self, other: Int) -> Int
Performs the |
operation.
impl<'a> BitOr<&'a Int> for i32
[src]
impl<'a> BitOr<&'a Int> for i32
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: &'a Int) -> Int
[src]
fn bitor(self, other: &'a Int) -> Int
Performs the |
operation.
impl BitXor<i32> for Int
[src]
impl BitXor<i32> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: i32) -> Int
[src]
fn bitxor(self, other: i32) -> Int
Performs the ^
operation.
impl<'a> BitXor<i32> for &'a Int
[src]
impl<'a> BitXor<i32> for &'a Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: i32) -> Int
[src]
fn bitxor(self, other: i32) -> Int
Performs the ^
operation.
impl BitXor<Int> for i32
[src]
impl BitXor<Int> for i32
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Int) -> Int
[src]
fn bitxor(self, other: Int) -> Int
Performs the ^
operation.
impl<'a> BitXor<&'a Int> for i32
[src]
impl<'a> BitXor<&'a Int> for i32
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: &'a Int) -> Int
[src]
fn bitxor(self, other: &'a Int) -> Int
Performs the ^
operation.
impl Add<usize> for Int
[src]
impl Add<usize> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: usize) -> Int
[src]
fn add(self, other: usize) -> Int
Performs the +
operation.
impl AddAssign<usize> for Int
[src]
impl AddAssign<usize> for Int
fn add_assign(&mut self, other: usize)
[src]
fn add_assign(&mut self, other: usize)
Performs the +=
operation.
impl Sub<usize> for Int
[src]
impl Sub<usize> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: usize) -> Int
[src]
fn sub(self, other: usize) -> Int
Performs the -
operation.
impl SubAssign<usize> for Int
[src]
impl SubAssign<usize> for Int
fn sub_assign(&mut self, other: usize)
[src]
fn sub_assign(&mut self, other: usize)
Performs the -=
operation.
impl Mul<usize> for Int
[src]
impl Mul<usize> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: usize) -> Int
[src]
fn mul(self, other: usize) -> Int
Performs the *
operation.
impl MulAssign<usize> for Int
[src]
impl MulAssign<usize> for Int
fn mul_assign(&mut self, other: usize)
[src]
fn mul_assign(&mut self, other: usize)
Performs the *=
operation.
impl Div<usize> for Int
[src]
impl Div<usize> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: usize) -> Int
[src]
fn div(self, other: usize) -> Int
Performs the /
operation.
impl DivAssign<usize> for Int
[src]
impl DivAssign<usize> for Int
fn div_assign(&mut self, other: usize)
[src]
fn div_assign(&mut self, other: usize)
Performs the /=
operation.
impl Rem<usize> for Int
[src]
impl Rem<usize> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: usize) -> Int
[src]
fn rem(self, other: usize) -> Int
Performs the %
operation.
impl RemAssign<usize> for Int
[src]
impl RemAssign<usize> for Int
fn rem_assign(&mut self, other: usize)
[src]
fn rem_assign(&mut self, other: usize)
Performs the %=
operation.
impl DivRem<usize> for Int
[src]
impl DivRem<usize> for Int
impl BitAndAssign<usize> for Int
[src]
impl BitAndAssign<usize> for Int
fn bitand_assign(&mut self, other: usize)
[src]
fn bitand_assign(&mut self, other: usize)
Performs the &=
operation.
impl BitOrAssign<usize> for Int
[src]
impl BitOrAssign<usize> for Int
fn bitor_assign(&mut self, other: usize)
[src]
fn bitor_assign(&mut self, other: usize)
Performs the |=
operation.
impl BitXorAssign<usize> for Int
[src]
impl BitXorAssign<usize> for Int
fn bitxor_assign(&mut self, other: usize)
[src]
fn bitxor_assign(&mut self, other: usize)
Performs the ^=
operation.
impl<'a> Add<usize> for &'a Int
[src]
impl<'a> Add<usize> for &'a Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: usize) -> Int
[src]
fn add(self, other: usize) -> Int
Performs the +
operation.
impl Add<Int> for usize
[src]
impl Add<Int> for usize
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Int
[src]
fn add(self, other: Int) -> Int
Performs the +
operation.
impl<'a> Add<&'a Int> for usize
[src]
impl<'a> Add<&'a Int> for usize
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Int
[src]
fn add(self, other: &'a Int) -> Int
Performs the +
operation.
impl<'a> Sub<usize> for &'a Int
[src]
impl<'a> Sub<usize> for &'a Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: usize) -> Int
[src]
fn sub(self, other: usize) -> Int
Performs the -
operation.
impl Sub<Int> for usize
[src]
impl Sub<Int> for usize
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Int) -> Int
[src]
fn sub(self, other: Int) -> Int
Performs the -
operation.
impl<'a> Sub<&'a Int> for usize
[src]
impl<'a> Sub<&'a Int> for usize
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: &'a Int) -> Int
[src]
fn sub(self, other: &'a Int) -> Int
Performs the -
operation.
impl<'a> Mul<usize> for &'a Int
[src]
impl<'a> Mul<usize> for &'a Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: usize) -> Int
[src]
fn mul(self, other: usize) -> Int
Performs the *
operation.
impl Mul<Int> for usize
[src]
impl Mul<Int> for usize
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Int
[src]
fn mul(self, other: Int) -> Int
Performs the *
operation.
impl<'a> Mul<&'a Int> for usize
[src]
impl<'a> Mul<&'a Int> for usize
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Int
[src]
fn mul(self, other: &'a Int) -> Int
Performs the *
operation.
impl<'a> Div<usize> for &'a Int
[src]
impl<'a> Div<usize> for &'a Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: usize) -> Int
[src]
fn div(self, other: usize) -> Int
Performs the /
operation.
impl Div<Int> for usize
[src]
impl Div<Int> for usize
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Int
[src]
fn div(self, other: Int) -> Int
Performs the /
operation.
impl<'a> Div<&'a Int> for usize
[src]
impl<'a> Div<&'a Int> for usize
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Int
[src]
fn div(self, other: &'a Int) -> Int
Performs the /
operation.
impl<'a> Rem<usize> for &'a Int
[src]
impl<'a> Rem<usize> for &'a Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: usize) -> Int
[src]
fn rem(self, other: usize) -> Int
Performs the %
operation.
impl Rem<Int> for usize
[src]
impl Rem<Int> for usize
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Int) -> Int
[src]
fn rem(self, other: Int) -> Int
Performs the %
operation.
impl<'a> Rem<&'a Int> for usize
[src]
impl<'a> Rem<&'a Int> for usize
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: &'a Int) -> Int
[src]
fn rem(self, other: &'a Int) -> Int
Performs the %
operation.
impl BitAnd<usize> for Int
[src]
impl BitAnd<usize> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: usize) -> Int
[src]
fn bitand(self, other: usize) -> Int
Performs the &
operation.
impl<'a> BitAnd<usize> for &'a Int
[src]
impl<'a> BitAnd<usize> for &'a Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: usize) -> Int
[src]
fn bitand(self, other: usize) -> Int
Performs the &
operation.
impl BitAnd<Int> for usize
[src]
impl BitAnd<Int> for usize
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Int) -> Int
[src]
fn bitand(self, other: Int) -> Int
Performs the &
operation.
impl<'a> BitAnd<&'a Int> for usize
[src]
impl<'a> BitAnd<&'a Int> for usize
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: &'a Int) -> Int
[src]
fn bitand(self, other: &'a Int) -> Int
Performs the &
operation.
impl BitOr<usize> for Int
[src]
impl BitOr<usize> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: usize) -> Int
[src]
fn bitor(self, other: usize) -> Int
Performs the |
operation.
impl<'a> BitOr<usize> for &'a Int
[src]
impl<'a> BitOr<usize> for &'a Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: usize) -> Int
[src]
fn bitor(self, other: usize) -> Int
Performs the |
operation.
impl BitOr<Int> for usize
[src]
impl BitOr<Int> for usize
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Int) -> Int
[src]
fn bitor(self, other: Int) -> Int
Performs the |
operation.
impl<'a> BitOr<&'a Int> for usize
[src]
impl<'a> BitOr<&'a Int> for usize
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: &'a Int) -> Int
[src]
fn bitor(self, other: &'a Int) -> Int
Performs the |
operation.
impl BitXor<usize> for Int
[src]
impl BitXor<usize> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: usize) -> Int
[src]
fn bitxor(self, other: usize) -> Int
Performs the ^
operation.
impl<'a> BitXor<usize> for &'a Int
[src]
impl<'a> BitXor<usize> for &'a Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: usize) -> Int
[src]
fn bitxor(self, other: usize) -> Int
Performs the ^
operation.
impl BitXor<Int> for usize
[src]
impl BitXor<Int> for usize
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Int) -> Int
[src]
fn bitxor(self, other: Int) -> Int
Performs the ^
operation.
impl<'a> BitXor<&'a Int> for usize
[src]
impl<'a> BitXor<&'a Int> for usize
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: &'a Int) -> Int
[src]
fn bitxor(self, other: &'a Int) -> Int
Performs the ^
operation.
impl Add<BaseInt> for Int
[src]
impl Add<BaseInt> for Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: BaseInt) -> Int
[src]
fn add(self, other: BaseInt) -> Int
Performs the +
operation.
impl AddAssign<BaseInt> for Int
[src]
impl AddAssign<BaseInt> for Int
fn add_assign(&mut self, other: BaseInt)
[src]
fn add_assign(&mut self, other: BaseInt)
Performs the +=
operation.
impl Sub<BaseInt> for Int
[src]
impl Sub<BaseInt> for Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: BaseInt) -> Int
[src]
fn sub(self, other: BaseInt) -> Int
Performs the -
operation.
impl SubAssign<BaseInt> for Int
[src]
impl SubAssign<BaseInt> for Int
fn sub_assign(&mut self, other: BaseInt)
[src]
fn sub_assign(&mut self, other: BaseInt)
Performs the -=
operation.
impl Mul<BaseInt> for Int
[src]
impl Mul<BaseInt> for Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: BaseInt) -> Int
[src]
fn mul(self, other: BaseInt) -> Int
Performs the *
operation.
impl MulAssign<BaseInt> for Int
[src]
impl MulAssign<BaseInt> for Int
fn mul_assign(&mut self, other: BaseInt)
[src]
fn mul_assign(&mut self, other: BaseInt)
Performs the *=
operation.
impl Div<BaseInt> for Int
[src]
impl Div<BaseInt> for Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: BaseInt) -> Int
[src]
fn div(self, other: BaseInt) -> Int
Performs the /
operation.
impl DivAssign<BaseInt> for Int
[src]
impl DivAssign<BaseInt> for Int
fn div_assign(&mut self, other: BaseInt)
[src]
fn div_assign(&mut self, other: BaseInt)
Performs the /=
operation.
impl Rem<BaseInt> for Int
[src]
impl Rem<BaseInt> for Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: BaseInt) -> Int
[src]
fn rem(self, other: BaseInt) -> Int
Performs the %
operation.
impl RemAssign<BaseInt> for Int
[src]
impl RemAssign<BaseInt> for Int
fn rem_assign(&mut self, other: BaseInt)
[src]
fn rem_assign(&mut self, other: BaseInt)
Performs the %=
operation.
impl DivRem<BaseInt> for Int
[src]
impl DivRem<BaseInt> for Int
impl BitAndAssign<BaseInt> for Int
[src]
impl BitAndAssign<BaseInt> for Int
fn bitand_assign(&mut self, other: BaseInt)
[src]
fn bitand_assign(&mut self, other: BaseInt)
Performs the &=
operation.
impl BitOrAssign<BaseInt> for Int
[src]
impl BitOrAssign<BaseInt> for Int
fn bitor_assign(&mut self, other: BaseInt)
[src]
fn bitor_assign(&mut self, other: BaseInt)
Performs the |=
operation.
impl BitXorAssign<BaseInt> for Int
[src]
impl BitXorAssign<BaseInt> for Int
fn bitxor_assign(&mut self, other: BaseInt)
[src]
fn bitxor_assign(&mut self, other: BaseInt)
Performs the ^=
operation.
impl<'a> Add<BaseInt> for &'a Int
[src]
impl<'a> Add<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: BaseInt) -> Int
[src]
fn add(self, other: BaseInt) -> Int
Performs the +
operation.
impl Add<Int> for BaseInt
[src]
impl Add<Int> for BaseInt
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Int
[src]
fn add(self, other: Int) -> Int
Performs the +
operation.
impl<'a> Add<&'a Int> for BaseInt
[src]
impl<'a> Add<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Int
[src]
fn add(self, other: &'a Int) -> Int
Performs the +
operation.
impl<'a> Sub<BaseInt> for &'a Int
[src]
impl<'a> Sub<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: BaseInt) -> Int
[src]
fn sub(self, other: BaseInt) -> Int
Performs the -
operation.
impl Sub<Int> for BaseInt
[src]
impl Sub<Int> for BaseInt
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: Int) -> Int
[src]
fn sub(self, other: Int) -> Int
Performs the -
operation.
impl<'a> Sub<&'a Int> for BaseInt
[src]
impl<'a> Sub<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the -
operator.
fn sub(self, other: &'a Int) -> Int
[src]
fn sub(self, other: &'a Int) -> Int
Performs the -
operation.
impl<'a> Mul<BaseInt> for &'a Int
[src]
impl<'a> Mul<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: BaseInt) -> Int
[src]
fn mul(self, other: BaseInt) -> Int
Performs the *
operation.
impl Mul<Int> for BaseInt
[src]
impl Mul<Int> for BaseInt
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Int
[src]
fn mul(self, other: Int) -> Int
Performs the *
operation.
impl<'a> Mul<&'a Int> for BaseInt
[src]
impl<'a> Mul<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Int
[src]
fn mul(self, other: &'a Int) -> Int
Performs the *
operation.
impl<'a> Div<BaseInt> for &'a Int
[src]
impl<'a> Div<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: BaseInt) -> Int
[src]
fn div(self, other: BaseInt) -> Int
Performs the /
operation.
impl Div<Int> for BaseInt
[src]
impl Div<Int> for BaseInt
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Int
[src]
fn div(self, other: Int) -> Int
Performs the /
operation.
impl<'a> Div<&'a Int> for BaseInt
[src]
impl<'a> Div<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Int
[src]
fn div(self, other: &'a Int) -> Int
Performs the /
operation.
impl<'a> Rem<BaseInt> for &'a Int
[src]
impl<'a> Rem<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: BaseInt) -> Int
[src]
fn rem(self, other: BaseInt) -> Int
Performs the %
operation.
impl Rem<Int> for BaseInt
[src]
impl Rem<Int> for BaseInt
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: Int) -> Int
[src]
fn rem(self, other: Int) -> Int
Performs the %
operation.
impl<'a> Rem<&'a Int> for BaseInt
[src]
impl<'a> Rem<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the %
operator.
fn rem(self, other: &'a Int) -> Int
[src]
fn rem(self, other: &'a Int) -> Int
Performs the %
operation.
impl BitAnd<BaseInt> for Int
[src]
impl BitAnd<BaseInt> for Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: BaseInt) -> Int
[src]
fn bitand(self, other: BaseInt) -> Int
Performs the &
operation.
impl<'a> BitAnd<BaseInt> for &'a Int
[src]
impl<'a> BitAnd<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: BaseInt) -> Int
[src]
fn bitand(self, other: BaseInt) -> Int
Performs the &
operation.
impl BitAnd<Int> for BaseInt
[src]
impl BitAnd<Int> for BaseInt
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: Int) -> Int
[src]
fn bitand(self, other: Int) -> Int
Performs the &
operation.
impl<'a> BitAnd<&'a Int> for BaseInt
[src]
impl<'a> BitAnd<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the &
operator.
fn bitand(self, other: &'a Int) -> Int
[src]
fn bitand(self, other: &'a Int) -> Int
Performs the &
operation.
impl BitOr<BaseInt> for Int
[src]
impl BitOr<BaseInt> for Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: BaseInt) -> Int
[src]
fn bitor(self, other: BaseInt) -> Int
Performs the |
operation.
impl<'a> BitOr<BaseInt> for &'a Int
[src]
impl<'a> BitOr<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: BaseInt) -> Int
[src]
fn bitor(self, other: BaseInt) -> Int
Performs the |
operation.
impl BitOr<Int> for BaseInt
[src]
impl BitOr<Int> for BaseInt
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: Int) -> Int
[src]
fn bitor(self, other: Int) -> Int
Performs the |
operation.
impl<'a> BitOr<&'a Int> for BaseInt
[src]
impl<'a> BitOr<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the |
operator.
fn bitor(self, other: &'a Int) -> Int
[src]
fn bitor(self, other: &'a Int) -> Int
Performs the |
operation.
impl BitXor<BaseInt> for Int
[src]
impl BitXor<BaseInt> for Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: BaseInt) -> Int
[src]
fn bitxor(self, other: BaseInt) -> Int
Performs the ^
operation.
impl<'a> BitXor<BaseInt> for &'a Int
[src]
impl<'a> BitXor<BaseInt> for &'a Int
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: BaseInt) -> Int
[src]
fn bitxor(self, other: BaseInt) -> Int
Performs the ^
operation.
impl BitXor<Int> for BaseInt
[src]
impl BitXor<Int> for BaseInt
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: Int) -> Int
[src]
fn bitxor(self, other: Int) -> Int
Performs the ^
operation.
impl<'a> BitXor<&'a Int> for BaseInt
[src]
impl<'a> BitXor<&'a Int> for BaseInt
type Output = Int
The resulting type after applying the ^
operator.
fn bitxor(self, other: &'a Int) -> Int
[src]
fn bitxor(self, other: &'a Int) -> Int
Performs the ^
operation.
impl PartialEq<i32> for Int
[src]
impl PartialEq<i32> for Int
fn eq(&self, other: &i32) -> bool
[src]
fn eq(&self, other: &i32) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Int> for i32
[src]
impl PartialEq<Int> for i32
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialOrd<i32> for Int
[src]
impl PartialOrd<i32> for Int
fn partial_cmp(&self, other: &i32) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &i32) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Int> for i32
[src]
impl PartialOrd<Int> for i32
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialEq<usize> for Int
[src]
impl PartialEq<usize> for Int
fn eq(&self, other: &usize) -> bool
[src]
fn eq(&self, other: &usize) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Int> for usize
[src]
impl PartialEq<Int> for usize
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialOrd<usize> for Int
[src]
impl PartialOrd<usize> for Int
fn partial_cmp(&self, other: &usize) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &usize) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Int> for usize
[src]
impl PartialOrd<Int> for usize
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialEq<u64> for Int
[src]
impl PartialEq<u64> for Int
fn eq(&self, other: &u64) -> bool
[src]
fn eq(&self, other: &u64) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Int> for u64
[src]
impl PartialEq<Int> for u64
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialOrd<u64> for Int
[src]
impl PartialOrd<u64> for Int
fn partial_cmp(&self, other: &u64) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &u64) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Int> for u64
[src]
impl PartialOrd<Int> for u64
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialEq<i64> for Int
[src]
impl PartialEq<i64> for Int
fn eq(&self, other: &i64) -> bool
[src]
fn eq(&self, other: &i64) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Int> for i64
[src]
impl PartialEq<Int> for i64
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialOrd<i64> for Int
[src]
impl PartialOrd<i64> for Int
fn partial_cmp(&self, other: &i64) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &i64) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Int> for i64
[src]
impl PartialOrd<Int> for i64
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl From<i8> for Int
[src]
impl From<i8> for Int
impl From<i16> for Int
[src]
impl From<i16> for Int
impl From<i32> for Int
[src]
impl From<i32> for Int
impl From<i64> for Int
[src]
impl From<i64> for Int
impl From<isize> for Int
[src]
impl From<isize> for Int
impl From<u8> for Int
[src]
impl From<u8> for Int
impl From<u16> for Int
[src]
impl From<u16> for Int
impl From<u32> for Int
[src]
impl From<u32> for Int
impl From<u64> for Int
[src]
impl From<u64> for Int
impl From<usize> for Int
[src]
impl From<usize> for Int
impl Binary for Int
[src]
impl Binary for Int
impl Octal for Int
[src]
impl Octal for Int
impl Display for Int
[src]
impl Display for Int
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl Debug for Int
[src]
impl Debug for Int
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl LowerHex for Int
[src]
impl LowerHex for Int
impl UpperHex for Int
[src]
impl UpperHex for Int
impl FromStr for Int
[src]
impl FromStr for Int
type Err = ParseIntError
The associated error which can be returned from parsing.
fn from_str(src: &str) -> Result<Int, ParseIntError>
[src]
fn from_str(src: &str) -> Result<Int, ParseIntError>
Parses a string s
to return a value of this type. Read more
impl<'a> From<&'a Int> for i8
[src]
impl<'a> From<&'a Int> for i8
impl<'a> From<&'a Int> for i16
[src]
impl<'a> From<&'a Int> for i16
impl<'a> From<&'a Int> for i32
[src]
impl<'a> From<&'a Int> for i32
impl<'a> From<&'a Int> for i64
[src]
impl<'a> From<&'a Int> for i64
impl<'a> From<&'a Int> for isize
[src]
impl<'a> From<&'a Int> for isize
impl<'a> From<&'a Int> for u8
[src]
impl<'a> From<&'a Int> for u8
impl<'a> From<&'a Int> for u16
[src]
impl<'a> From<&'a Int> for u16
impl<'a> From<&'a Int> for u32
[src]
impl<'a> From<&'a Int> for u32
impl<'a> From<&'a Int> for u64
[src]
impl<'a> From<&'a Int> for u64
impl<'a> From<&'a Int> for usize
[src]
impl<'a> From<&'a Int> for usize
impl Zero for Int
[src]
impl Zero for Int
fn zero() -> Int
[src]
fn zero() -> Int
Returns the additive identity element of Self
, 0
. Read more
fn is_zero(&self) -> bool
[src]
fn is_zero(&self) -> bool
Returns true
if self
is equal to the additive identity.
impl One for Int
[src]
impl One for Int
fn one() -> Int
[src]
fn one() -> Int
Returns the multiplicative identity element of Self
, 1
. Read more
fn is_one(&self) -> bool where
Self: PartialEq<Self>,
[src]
fn is_one(&self) -> bool where
Self: PartialEq<Self>,
Returns true
if self
is equal to the multiplicative identity. Read more
impl Num for Int
[src]
impl Num for Int
type FromStrRadixErr = ParseIntError
fn from_str_radix(src: &str, radix: u32) -> Result<Int, ParseIntError>
[src]
fn from_str_radix(src: &str, radix: u32) -> Result<Int, ParseIntError>
Convert from a string and radix <= 36. Read more
impl Integer for Int
[src]
impl Integer for Int
fn div_floor(&self, other: &Int) -> Int
[src]
fn div_floor(&self, other: &Int) -> Int
Floored integer division. Read more
fn mod_floor(&self, other: &Int) -> Int
[src]
fn mod_floor(&self, other: &Int) -> Int
Floored integer modulo, satisfying: Read more
fn gcd(&self, other: &Int) -> Int
[src]
fn gcd(&self, other: &Int) -> Int
Greatest Common Divisor (GCD). Read more
fn lcm(&self, other: &Int) -> Int
[src]
fn lcm(&self, other: &Int) -> Int
Lowest Common Multiple (LCM). Read more
fn divides(&self, other: &Int) -> bool
[src]
fn divides(&self, other: &Int) -> bool
Deprecated, use is_multiple_of
instead.
fn is_multiple_of(&self, other: &Int) -> bool
[src]
fn is_multiple_of(&self, other: &Int) -> bool
Returns true
if self
is a multiple of other
. Read more
fn is_even(&self) -> bool
[src]
fn is_even(&self) -> bool
Returns true
if the number is even. Read more
fn is_odd(&self) -> bool
[src]
fn is_odd(&self) -> bool
Returns true
if the number is odd. Read more
fn div_rem(&self, other: &Int) -> (Int, Int)
[src]
fn div_rem(&self, other: &Int) -> (Int, Int)
Simultaneous truncated integer division and modulus. Returns (quotient, remainder)
. Read more
fn div_mod_floor(&self, other: &Self) -> (Self, Self)
[src]
fn div_mod_floor(&self, other: &Self) -> (Self, Self)
Simultaneous floored integer division and modulus. Returns (quotient, remainder)
. Read more
impl Step for Int
[src]
impl Step for Int
fn steps_between(start: &Int, end: &Int) -> Option<usize>
[src]
fn steps_between(start: &Int, end: &Int) -> Option<usize>
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Returns the number of steps between two step objects. The count is inclusive of start
and exclusive of end
. Read more
fn replace_one(&mut self) -> Self
[src]
fn replace_one(&mut self) -> Self
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Replaces this step with 1
, returning itself
fn replace_zero(&mut self) -> Self
[src]
fn replace_zero(&mut self) -> Self
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Replaces this step with 0
, returning itself
fn add_one(&self) -> Self
[src]
fn add_one(&self) -> Self
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Adds one to this step, returning the result
fn sub_one(&self) -> Self
[src]
fn sub_one(&self) -> Self
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Subtracts one to this step, returning the result
fn add_usize(&self, n: usize) -> Option<Self>
[src]
fn add_usize(&self, n: usize) -> Option<Self>
🔬 This is a nightly-only experimental API. (step_trait
)
likely to be replaced by finer-grained traits
Add an usize, returning None on overflow
impl PartialEq<Int> for Rational
[src]
impl PartialEq<Int> for Rational
fn eq(&self, other: &Int) -> bool
[src]
fn eq(&self, other: &Int) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialEq<Rational> for Int
[src]
impl PartialEq<Rational> for Int
fn eq(&self, other: &Rational) -> bool
[src]
fn eq(&self, other: &Rational) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl PartialOrd<Int> for Rational
[src]
impl PartialOrd<Int> for Rational
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Int) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl PartialOrd<Rational> for Int
[src]
impl PartialOrd<Rational> for Int
fn partial_cmp(&self, other: &Rational) -> Option<Ordering>
[src]
fn partial_cmp(&self, other: &Rational) -> Option<Ordering>
This method returns an ordering between self
and other
values if one exists. Read more
fn lt(&self, other: &Rhs) -> bool
1.0.0[src]
fn lt(&self, other: &Rhs) -> bool
This method tests less than (for self
and other
) and is used by the <
operator. Read more
fn le(&self, other: &Rhs) -> bool
1.0.0[src]
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for self
and other
) and is used by the <=
operator. Read more
fn gt(&self, other: &Rhs) -> bool
1.0.0[src]
fn gt(&self, other: &Rhs) -> bool
This method tests greater than (for self
and other
) and is used by the >
operator. Read more
fn ge(&self, other: &Rhs) -> bool
1.0.0[src]
fn ge(&self, other: &Rhs) -> bool
This method tests greater than or equal to (for self
and other
) and is used by the >=
operator. Read more
impl AddAssign<Int> for Rational
[src]
impl AddAssign<Int> for Rational
fn add_assign(&mut self, other: Int)
[src]
fn add_assign(&mut self, other: Int)
Performs the +=
operation.
impl<'a> AddAssign<&'a Int> for Rational
[src]
impl<'a> AddAssign<&'a Int> for Rational
fn add_assign(&mut self, other: &'a Int)
[src]
fn add_assign(&mut self, other: &'a Int)
Performs the +=
operation.
impl Add<Int> for Rational
[src]
impl Add<Int> for Rational
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Rational
[src]
fn add(self, other: Int) -> Rational
Performs the +
operation.
impl<'a> Add<&'a Int> for Rational
[src]
impl<'a> Add<&'a Int> for Rational
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Rational
[src]
fn add(self, other: &'a Int) -> Rational
Performs the +
operation.
impl<'a> Add<Int> for &'a Rational
[src]
impl<'a> Add<Int> for &'a Rational
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: Int) -> Rational
[src]
fn add(self, other: Int) -> Rational
Performs the +
operation.
impl<'a, 'b> Add<&'a Int> for &'b Rational
[src]
impl<'a, 'b> Add<&'a Int> for &'b Rational
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: &'a Int) -> Rational
[src]
fn add(self, other: &'a Int) -> Rational
Performs the +
operation.
impl Add<Rational> for Int
[src]
impl Add<Rational> for Int
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: Rational) -> Rational
[src]
fn add(self, other: Rational) -> Rational
Performs the +
operation.
impl<'a> Add<&'a Rational> for Int
[src]
impl<'a> Add<&'a Rational> for Int
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: &'a Rational) -> Rational
[src]
fn add(self, other: &'a Rational) -> Rational
Performs the +
operation.
impl<'a> Add<Rational> for &'a Int
[src]
impl<'a> Add<Rational> for &'a Int
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: Rational) -> Rational
[src]
fn add(self, other: Rational) -> Rational
Performs the +
operation.
impl<'a, 'b> Add<&'a Rational> for &'b Int
[src]
impl<'a, 'b> Add<&'a Rational> for &'b Int
type Output = Rational
The resulting type after applying the +
operator.
fn add(self, other: &'a Rational) -> Rational
[src]
fn add(self, other: &'a Rational) -> Rational
Performs the +
operation.
impl MulAssign<Int> for Rational
[src]
impl MulAssign<Int> for Rational
fn mul_assign(&mut self, other: Int)
[src]
fn mul_assign(&mut self, other: Int)
Performs the *=
operation.
impl<'a> MulAssign<&'a Int> for Rational
[src]
impl<'a> MulAssign<&'a Int> for Rational
fn mul_assign(&mut self, other: &'a Int)
[src]
fn mul_assign(&mut self, other: &'a Int)
Performs the *=
operation.
impl Mul<Int> for Rational
[src]
impl Mul<Int> for Rational
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Rational
[src]
fn mul(self, other: Int) -> Rational
Performs the *
operation.
impl<'a> Mul<&'a Int> for Rational
[src]
impl<'a> Mul<&'a Int> for Rational
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Rational
[src]
fn mul(self, other: &'a Int) -> Rational
Performs the *
operation.
impl<'a> Mul<Int> for &'a Rational
[src]
impl<'a> Mul<Int> for &'a Rational
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: Int) -> Rational
[src]
fn mul(self, other: Int) -> Rational
Performs the *
operation.
impl<'a, 'b> Mul<&'a Int> for &'b Rational
[src]
impl<'a, 'b> Mul<&'a Int> for &'b Rational
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: &'a Int) -> Rational
[src]
fn mul(self, other: &'a Int) -> Rational
Performs the *
operation.
impl Mul<Rational> for Int
[src]
impl Mul<Rational> for Int
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: Rational) -> Rational
[src]
fn mul(self, other: Rational) -> Rational
Performs the *
operation.
impl<'a> Mul<&'a Rational> for Int
[src]
impl<'a> Mul<&'a Rational> for Int
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: &'a Rational) -> Rational
[src]
fn mul(self, other: &'a Rational) -> Rational
Performs the *
operation.
impl<'a> Mul<Rational> for &'a Int
[src]
impl<'a> Mul<Rational> for &'a Int
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: Rational) -> Rational
[src]
fn mul(self, other: Rational) -> Rational
Performs the *
operation.
impl<'a, 'b> Mul<&'a Rational> for &'b Int
[src]
impl<'a, 'b> Mul<&'a Rational> for &'b Int
type Output = Rational
The resulting type after applying the *
operator.
fn mul(self, other: &'a Rational) -> Rational
[src]
fn mul(self, other: &'a Rational) -> Rational
Performs the *
operation.
impl DivAssign<Int> for Rational
[src]
impl DivAssign<Int> for Rational
fn div_assign(&mut self, other: Int)
[src]
fn div_assign(&mut self, other: Int)
Performs the /=
operation.
impl<'a> DivAssign<&'a Int> for Rational
[src]
impl<'a> DivAssign<&'a Int> for Rational
fn div_assign(&mut self, other: &'a Int)
[src]
fn div_assign(&mut self, other: &'a Int)
Performs the /=
operation.
impl Div<Int> for Rational
[src]
impl Div<Int> for Rational
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Rational
[src]
fn div(self, other: Int) -> Rational
Performs the /
operation.
impl<'a> Div<&'a Int> for Rational
[src]
impl<'a> Div<&'a Int> for Rational
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Rational
[src]
fn div(self, other: &'a Int) -> Rational
Performs the /
operation.
impl<'a> Div<Int> for &'a Rational
[src]
impl<'a> Div<Int> for &'a Rational
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: Int) -> Rational
[src]
fn div(self, other: Int) -> Rational
Performs the /
operation.
impl<'a, 'b> Div<&'a Int> for &'b Rational
[src]
impl<'a, 'b> Div<&'a Int> for &'b Rational
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: &'a Int) -> Rational
[src]
fn div(self, other: &'a Int) -> Rational
Performs the /
operation.
impl Div<Rational> for Int
[src]
impl Div<Rational> for Int
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: Rational) -> Rational
[src]
fn div(self, other: Rational) -> Rational
Performs the /
operation.
impl<'a> Div<&'a Rational> for Int
[src]
impl<'a> Div<&'a Rational> for Int
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: &'a Rational) -> Rational
[src]
fn div(self, other: &'a Rational) -> Rational
Performs the /
operation.
impl<'a> Div<Rational> for &'a Int
[src]
impl<'a> Div<Rational> for &'a Int
type Output = Rational
The resulting type after applying the /
operator.
fn div(self, other: Rational) -> Rational
[src]
fn div(self, other: Rational) -> Rational
Performs the /
operation.
impl<'a, 'b> Div<&'a Rational> for &'b Int
[src]
impl<'a, 'b> Div<&'a Rational> for &'b Int