Rust/combine number.rs example

#1

Can anyone get https://github.com/Marwes/combine/blob/master/examples/number.rs#L25 to work ?

I don’t have str::from_utf8_unchecked , so I replaced it with str::from_utf8 . However, both functions expect Vec<u8> . What am I doing wrong / how do we fix this?

#2

There is:

https://doc.rust-lang.org/std/str/fn.from_utf8_unchecked.html

The Vec one is for owned String, not borrowed str.