Function core::num::flt2dec::digits_to_dec_str
[−]
[src]
fn digits_to_dec_str<'a>(buf: &'a [u8], exp: i16, frac_digits: usize, parts: &'a mut [Part<'a>]) -> &'a [Part<'a>]
Unstable (
flt2dec
): internal routines only exposed for testing
Formats given decimal digits 0.<...buf...> * 10^exp
into the decimal form
with at least given number of fractional digits. The result is stored to
the supplied parts array and a slice of written parts is returned.
frac_digits
can be less than the number of actual fractional digits in buf
;
it will be ignored and full digits will be printed. It is only used to print
additional zeroes after rendered digits. Thus frac_digits
of 0 means that
it will only print given digits and nothing else.