fn max_prec_for_len(len: usize) -> Result<usize, std::num::TryFromIntError> {
    Ok((2.0_f64.powi(i32::try_from(8 * len - 1)?) - 1.0 as f64)
        .log10()
        .floor() as usize)
}
/// Compute the maximum decimal value precision of a byte array of length `len` could hold.
Compute the maximum decimal value precision of a byte array of length `len` could hold.
Compute the maximum decimal value precision of a byte array of length ` len ` could hold .
fn max_prec_for_len(len: usize) -> Result<usize, std::num::TryFromIntError> {
    Ok((2.0_f64.powi(i32::try_from(8 * len - 1)?) - 1.0 as f64)
        .log10()
        .floor() as usize)
}
fn max_prec_for_len ( len : usize ) -> Result < usize , std :: num :: TryFromIntError > { Ok ( ( 2.0_f64 . powi ( i32 :: try_from ( 8 * len - 1 ) ? ) - 1.0 as f64 ) . log10 ( ) . floor ( ) as usize ) }
Compute the maximum decimal value precision of a byte array of length `len` could hold.
Compute the maximum decimal value precision of a byte array of length ` len ` could hold .
len
usize