Issue #7501 emove unused time function in time module of profile

This commit is contained in:
Mathieu Rheaume 2015-09-01 21:51:57 -04:00
parent e46499a5df
commit ba1109b920

View file

@ -209,16 +209,3 @@ impl Profiler {
println!("");
}
}
pub fn time<T, F>(msg: &str, callback: F) -> T
where F: Fn() -> T
{
let start_time = precise_time_ns();
let val = callback();
let end_time = precise_time_ns();
let ms = (end_time - start_time) as f64 / 1000000f64;
if ms >= 5f64 {
debug!("{} took {} ms", msg, ms);
}
return val;
}