std: Remove generics from Option::expect
This commit removes the <M: Any + Send> type parameter from Option::expect in favor of just taking a hard-coded `&str` argument. This allows this function to move into libcore. Previous code using strings with `expect` will continue to work, but code using this implicitly to transmit task failure will need to unwrap manually with a `match` statement. [breaking-change] Closes #14008
Showing
src/libstd/option.rs
已删除
100644 → 0
想要评论请 注册 或 登录