Hacker News new | ask | show | jobs
by blegr 771 days ago
Now that GP said it, it'd be nice to be able to write "some_map[i].value_or(some_value)".
1 comments

You can do this in rust with Vec::get, which returns an Option<&T>.