Purging .derefs, fixing clippy warnings. (#1890)

* Fixing clippy warnings

* Purging derefs

* Simplifying engine derefs

* Simplifying more engine derefs
This commit is contained in:
Tomasz Drwięga
2016-08-10 16:29:40 +02:00
committed by Arkadiy Paronyan
parent 8018b69440
commit a427208f79
42 changed files with 160 additions and 182 deletions

View File

@@ -17,7 +17,6 @@
//! Panic utilities
use std::thread;
use std::ops::DerefMut;
use std::sync::Arc;
use std::default::Default;
@@ -91,7 +90,7 @@ impl PanicHandler {
/// You should use `catch_panic` instead of calling this method explicitly.
pub fn notify_all(&self, r: String) {
let mut listeners = self.listeners.lock();
for listener in listeners.deref_mut() {
for mut listener in &mut **listeners {
listener.call(&r);
}
}