Remove trait bounds from MessageError struct

Trait bounds are for behavior, not data. It is sufficient for the bounds
to be on the impl blocks i.e. the behavior only.
This commit is contained in:
David Tolnay 2019-10-04 23:59:20 -04:00
parent 7dcc85121b
commit eac05d1c69
No known key found for this signature in database
GPG Key ID: F9BA143B95FF6D82

View File

@ -236,9 +236,7 @@ struct TraitObject {
}
#[repr(transparent)]
struct MessageError<M>(M)
where
M: Display + Debug;
struct MessageError<M>(M);
impl<M> Debug for MessageError<M>
where