pub fn to_string<N: ToLexical>(n: N) -> String
Expand description

High-level conversion of a number to a decimal-encoded string.

  • n - Number to convert to string.

Examples

assert_eq!(lexical::to_string(5), "5");
assert_eq!(lexical::to_string(0.0), "0.0");