5 ms·
If you don't mind unstable you can implement it yourself for Option. https://doc.rust-lang.org/src/core/up/src/libcore/ops.rs.html#2815-2830 https://doc.rust-la
by neikos 10y ago
If you don't mind unstable you can implement it yourself for Option. https://doc.rust-lang.org/src/core/up/src/libcore/ops.rs.html#2815-2830 https://doc.rust-lang.org/src/core/up/src/libcore/ops.rs.htm...
I am sure it will come soon (tm) though
- saghm 10y agoI usually just implement a `try_option` macro, which works well enough. I just wish it were a built-in thing in the language, as I don't like having to implement it for every new project, but I really don't want to include an external crate just for one macro.