Rollup merge of #71633 - a1phyr:infallible_error, r=dtolnay
Impl Error for Infallible This PR only changes the place where `impl Error for Infallible` is documented, as one could think that it is not the case when reading https://doc.rust-lang.org/nightly/std/convert/enum.Infallible.html. Fixes #70842
This commit is contained in:
commit
a08a03ced7
@ -14,6 +14,7 @@
|
|||||||
// reconsider what crate these items belong in.
|
// reconsider what crate these items belong in.
|
||||||
|
|
||||||
use core::array;
|
use core::array;
|
||||||
|
use core::convert::Infallible;
|
||||||
|
|
||||||
use crate::alloc::{AllocErr, LayoutErr};
|
use crate::alloc::{AllocErr, LayoutErr};
|
||||||
use crate::any::TypeId;
|
use crate::any::TypeId;
|
||||||
@ -474,7 +475,7 @@ impl Error for string::FromUtf16Error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[stable(feature = "str_parse_error2", since = "1.8.0")]
|
#[stable(feature = "str_parse_error2", since = "1.8.0")]
|
||||||
impl Error for string::ParseError {
|
impl Error for Infallible {
|
||||||
fn description(&self) -> &str {
|
fn description(&self) -> &str {
|
||||||
match *self {}
|
match *self {}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user