Re:Rust 2018 is here, but what is it?
by throwaway487550 on Friday December 07, 2018 @11:45AM
(#18629149)
How could I write this in Rust?
And boy, no TCO. What a shame.
[ Parent
| on HN ]
Re:Rust 2018 is here, but what is it?
by steveklabnik on Friday December 07, 2018 @12:05PM
(#18629338)
You can only use irrefutable patterns. You’d write this by writing a match in the body. There’s been talk of maybe supporting this directy but it’s so niche there’s not a ton of demand.
There is TCO, just not guaranteed. We’d like it; we have even reserved a keyword. Needs an RFC though.