Rollup merge of #109793 - lukas-code:negative-impl-comment, r=scottmcm
add comment to `impl !Error for &str` I saw this impl in the [standard library docs](https://doc.rust-lang.org/nightly/core/error/trait.Error.html#impl-Error-for-%26str) and wondered why it's needed. This commit adds a comment to explain its existence.
This commit is contained in:
commit
ec276c7e67
@ -2655,5 +2655,6 @@ struct UnsafeBytesToStr impl<'a> Fn = |bytes: &'a [u8]| -> &'a str {
|
||||
};
|
||||
}
|
||||
|
||||
// This is required to make `impl From<&str> for Box<dyn Error>` and `impl<E> From<E> for Box<dyn Error>` not overlap.
|
||||
#[stable(feature = "rust1", since = "1.0.0")]
|
||||
impl !crate::error::Error for &str {}
|
||||
|
Loading…
Reference in New Issue
Block a user