diff options
| author | Jimmy Cuadra <jimmy@jimmycuadra.com> | 2017-09-23 17:08:16 -0700 |
|---|---|---|
| committer | Jimmy Cuadra <jimmy@jimmycuadra.com> | 2017-09-23 17:27:02 -0700 |
| commit | 4d2a8c527880a56db3b410450fa2b6cbf0cbe3a8 (patch) | |
| tree | 3873c744e21e31a23530a42e6fdedca0c4c62135 /src/libstd/error.rs | |
| parent | 79f2439aa698c7eefa089ad05027826d7911780f (diff) | |
| download | rust-4d2a8c527880a56db3b410450fa2b6cbf0cbe3a8.tar.gz rust-4d2a8c527880a56db3b410450fa2b6cbf0cbe3a8.zip | |
Simplify implementation of Display and Error for convert::Infallible.
Diffstat (limited to 'src/libstd/error.rs')
| -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 5cb2b00334d..6a4de4ecbff 100644 --- a/src/libstd/error.rs +++ b/src/libstd/error.rs @@ -351,7 +351,8 @@ impl Error for char::ParseCharError { #[unstable(feature = "try_from", issue = "33417")] impl Error for convert::Infallible { fn description(&self) -> &str { - "an error of this type can never exist" + match *self { + } } } |
