commit | 0e85fede47a53cb25e81380f9dd387fdc3f6c791 | [log] [tgz] |
---|---|---|
author | Android Build Coastguard Worker <[email protected]> | Tue Aug 27 23:13:08 2024 +0000 |
committer | Android Build Coastguard Worker <[email protected]> | Tue Aug 27 23:13:08 2024 +0000 |
tree | cddf0242bb53f39d0f5b9d0b3c46af8a8386b4a8 | |
parent | 43565d896723f71aced882915a2c2fb41679a3ae [diff] | |
parent | ec62bc1680ff8c000bd4693fc3c3a17313d0ed39 [diff] |
Snap for 12283639 from ec62bc1680ff8c000bd4693fc3c3a17313d0ed39 to 24Q4-release Change-Id: I38bd7e57b557bd9e0e543b17f74e4cc70b4e20f3
This crate provides a fast conversion of integer primitives to decimal strings. The implementation comes straight from libcore but avoids the performance penalty of going through core::fmt::Formatter
.
See also ryu
for printing floating point primitives.
Version requirement: rustc 1.36+
[dependencies] itoa = "1.0"
fn main() { let mut buffer = itoa::Buffer::new(); let printed = buffer.format(128u64); assert_eq!(printed, "128"); }