diff options
| author | Benoît du Garreau <bdgdlm@outlook.com> | 2020-04-07 14:51:47 +0200 |
|---|---|---|
| committer | Benoît du Garreau <bdgdlm@outlook.com> | 2020-04-28 11:22:42 +0200 |
| commit | ef485c6fa97a562b0bc559ffbe38fee9bf1f745b (patch) | |
| tree | 3aa75e807504bcbeed9daffdbe73d37a0b3f6d50 | |
| parent | fb5615a4771ea3d54256f969dc84d2dfd38d812c (diff) | |
| download | rust-ef485c6fa97a562b0bc559ffbe38fee9bf1f745b.tar.gz rust-ef485c6fa97a562b0bc559ffbe38fee9bf1f745b.zip | |
Impl Error for Infallible
| -rw-r--r-- | src/libstd/error.rs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/libstd/error.rs b/src/libstd/error.rs index 24b57f12e8d..3b4cb859dd4 100644 --- a/src/libstd/error.rs +++ b/src/libstd/error.rs @@ -14,6 +14,7 @@ // reconsider what crate these items belong in. use core::array; +use core::convert::Infallible; use crate::alloc::{AllocErr, LayoutErr}; use crate::any::TypeId; @@ -474,7 +475,7 @@ impl Error for string::FromUtf16Error { } #[stable(feature = "str_parse_error2", since = "1.8.0")] -impl Error for string::ParseError { +impl Error for Infallible { fn description(&self) -> &str { match *self {} } |
