Rollup merge of #40566 - clarcharr:never_error, r=sfackler
Implement std::error::Error for !.
This commit is contained in:
commit
4e9033124b
|
@ -216,6 +216,11 @@ impl<'a> From<&'a str> for Box<Error> {
|
|||
}
|
||||
}
|
||||
|
||||
#[stable(feature = "never_error", since = "1.18.0")]
|
||||
impl Error for ! {
|
||||
fn description(&self) -> &str { *self }
|
||||
}
|
||||
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl Error for str::ParseBoolError {
|
||||
fn description(&self) -> &str { "failed to parse bool" }
|
||||
|
|
|
@ -272,6 +272,7 @@
|
|||
#![feature(linkage)]
|
||||
#![feature(macro_reexport)]
|
||||
#![feature(needs_panic_runtime)]
|
||||
#![feature(never_type)]
|
||||
#![feature(num_bits_bytes)]
|
||||
#![feature(old_wrapping)]
|
||||
#![feature(on_unimplemented)]
|
||||
|
|
Loading…
Reference in New Issue