2 ms·
I don't think I agree that we need three different things to handle them. We already have a general mechanism to convert an Option<T> to a T and panic on None,
by couchand 4y ago
I don't think I agree that we need three different things to handle them. We already have a general mechanism to convert an Option<T> to a T and panic on None, a method which shall not be named. So we just need get and get_unchecked, really.
If the index operator is offered as sugar over one of the basic operations, great. But why add sugar for a method call that we actually don't ever want to see in production code?