atoi-rs
Parse integers directly from [u8]
slices in safe code
Examples
Parsing to digits from a slice
use atoi;
assert_eq!;
Additional bytes after the number are ignored
assert_eq!;
The second number indicates how many bytes were 'used'
assert_eq!
(0,0)
is returned if the slice does not start with a digit
assert_eq!;
While signed integer types are supported...
assert_eq!;
... signs currently are not (subject to change in future versions)
assert_eq!;