]> git.lizzy.rs Git - rust.git/blobdiff - src/libstd/error.rs
Format libstd/sys with rustfmt
[rust.git] / src / libstd / error.rs
index df24b6635f41160c06690c7cde48fa0dcf15002e..ec1c444bcf8c80fee608b20ed02fd2a312789c3a 100644 (file)
@@ -206,7 +206,7 @@ fn type_id(&self, _: private::Internal) -> TypeId where Self: 'static {
         TypeId::of::<Self>()
     }
 
-    /// Returns a stack backtrace, if available, of where this error ocurred.
+    /// Returns a stack backtrace, if available, of where this error occurred.
     ///
     /// This function allows inspecting the location, in code, of where an error
     /// happened. The returned `Backtrace` contains information about the stack
@@ -465,7 +465,7 @@ fn from(err: Cow<'a, str>) -> Box<dyn Error> {
     }
 }
 
-#[unstable(feature = "never_type", issue = "35121")]
+#[stable(feature = "never_type", since = "1.41.0")]
 impl Error for ! {
     fn description(&self) -> &str { *self }
 }
@@ -551,13 +551,6 @@ fn description(&self) -> &str {
     }
 }
 
-#[stable(feature = "str_parse_error2", since = "1.8.0")]
-impl Error for string::ParseError {
-    fn description(&self) -> &str {
-        match *self {}
-    }
-}
-
 #[stable(feature = "decode_utf16", since = "1.9.0")]
 impl Error for char::DecodeUtf16Error {
     fn description(&self) -> &str {
@@ -791,7 +784,7 @@ pub fn chain(&self) -> Chain<'_> {
 ///
 /// [`Error`]: trait.Error.html
 #[unstable(feature = "error_iter", issue = "58520")]
-#[derive(Copy, Clone, Debug)]
+#[derive(Clone, Debug)]
 pub struct Chain<'a> {
     current: Option<&'a (dyn Error + 'static)>,
 }