1
Fork 0

Remove an unnecessary 'static bound in the impl of Debug for Mutex.

There is no reason to require T: 'static; the bound appears to be
a historical artifact.
This commit is contained in:
Jonathan Reem 2016-02-05 01:19:29 -08:00
parent 2ad6dc2556
commit ca72440e69

View file

@ -311,7 +311,7 @@ impl<T: ?Sized> Drop for Mutex<T> {
}
#[stable(feature = "rust1", since = "1.0.0")]
impl<T: ?Sized + fmt::Debug + 'static> fmt::Debug for Mutex<T> {
impl<T: ?Sized + fmt::Debug> fmt::Debug for Mutex<T> {
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
match self.try_lock() {
Ok(guard) => write!(f, "Mutex {{ data: {:?} }}", &*guard),