type i8
impl i8С версии. 1.0.0-beta
Методы
checked_add | (o: i8) -> i8?Checked addition |
checked_sub | (o: i8) -> i8?Checked subtraction |
checked_mul | (o: i8) -> i8?Checked multiplication |
checked_div | (o: i8) -> i8?Checked division (truncating toward zero) |
checked_rem | (o: i8) -> i8?Checked remainder |
wrapping_add | (o: i8) -> i8Addition that wraps around at the bounds of the type (two's complement) instead of panicking. |
wrapping_sub | (o: i8) -> i8Subtraction that wraps around at the bounds of the type instead of panicking. |
wrapping_mul | (o: i8) -> i8Multiplication that wraps around at the bounds of the type instead of panicking. |
saturating_add | (o: i8) -> i8Addition that stops at the nearest bound of the type instead of panicking. |
saturating_sub | (o: i8) -> i8Subtraction that stops at the nearest bound of the type instead of panicking. |
saturating_mul | (o: i8) -> i8Multiplication that stops at the nearest bound of the type instead of panicking. |
wrap | () -> Ux.wrap<U>(): converts to the numeric type U; an integer that does not fit wraps around (keeps the low bits), a float is truncated toward zero (§3.1). |
try | () -> U | OutOfRangex.try<U>(): checked conversion to the numeric type U (§3.1). |
abs | () -> i8The absolute value. |
signum | () -> i8-1, 0 or 1 for a negative, zero or positive value. |
min | (o: i8) -> i8The smaller of the two values. |
max | (o: i8) -> i8The larger of the two values. |
clamp | (lo: i8, hi: i8) -> i8lo when the value is below it, hi when it is above, the value itself otherwise. |
pow | (e: u32) -> i8Power by repeated squaring; panics on overflow like *. |
toString | () -> strThe decimal text of the value (what interpolation {x} shows). |
Определено в: std/core/numbers.oxl:1034