logoalt Hacker News

ammar_az • yesterday at 7:22 PM • 2 replies • view on HN

This release is so big that multiple useful stabilized API aren't event mentioned in the blog post like:

- bool::toggle() https://doc.rust-lang.org/stable/std/primitive.bool.html#met...

- Box::map() https://doc.rust-lang.org/stable/std/boxed/struct.Box.html#m...

- str::trim_prefix(), str::trim_suffix, Path::trim_prefix()


Replies

jacksontheel • yesterday at 9:58 PM

I'm at a loss with the bool toggle method. Why would x = !x not be good enough?

➕ show 3 replies
afdbcreid • yesterday at 7:32 PM

They are mentioned in the blog post, under "Stabilized APIs".