Trait UpperExp
trait UpperExp: PointeeSized
E formatting.
The UpperExp trait should format its output in scientific notation with an upper-case E.
For more information on formatters, see the module-level documentation.
Examples
Basic usage with f64:
let x = 42.0; // 42.0 is '4.2E1' in scientific notation
assert_eq!;
Implementing UpperExp on a type:
use fmt;
;
let l = Length;
assert_eq!;
assert_eq!;
Required Methods
fn fmt(self: &Self, f: &mut Formatter<'_>) -> ResultFormats the value using the given formatter.
Errors
This function should return
Errif, and only if, the providedFormatterreturnsErr. String formatting is considered an infallible operation; this function only returns aResultbecause writing to the underlying stream might fail and it must provide a way to propagate the fact that an error has occurred back up the stack.
Implementors
impl UpperExp for usizeimpl UpperExp for u16impl UpperExp for i128impl UpperExp for f32impl UpperExp for i32impl UpperExp for u128impl<T> UpperExp for NonZero<T>impl UpperExp for f64impl UpperExp for u32impl<T: PointeeSized + UpperExp> UpperExp for &Timpl UpperExp for f16impl UpperExp for i64impl<T: PointeeSized + UpperExp> UpperExp for &mut Timpl UpperExp for i8impl UpperExp for u64impl UpperExp for u8impl UpperExp for isizeimpl UpperExp for i16