New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

foo.unwrap_or(panic!(…)) #19

P1start opened this Issue Dec 1, 2014 · 2 comments


None yet
4 participants

P1start commented Dec 1, 2014

This should either be .expect() or .unwrap_or_else(|| panic!()) (if they want the formatting panic provides). Ideally this would be generalised to any diverging function (fn(…) -> !) as well.


This comment has been minimized.

lfairy commented May 3, 2015

Note that macro expansion runs before type checking runs before lints, so we'll need to match against std::rt::begin_unwind and friends instead.


This comment has been minimized.


llogiq commented May 3, 2015

Similarly, one can implement a lot of Option's API in terms of itself. A number of hints to use the right one will certainly be helpful for a number of people.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment