Skip to content

Commit 97ab37e

Browse files
committed
Remove some dead code
1 parent 256a6e4 commit 97ab37e

File tree

1 file changed

+1
-17
lines changed

1 file changed

+1
-17
lines changed

src/librustc/util/profiling.rs

Lines changed: 1 addition & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -161,16 +161,6 @@ pub struct SelfProfiler {
161161
current_timer: Instant,
162162
}
163163

164-
pub struct ProfilerActivity<'a>(ProfileCategory, &'a mut SelfProfiler);
165-
166-
impl<'a> Drop for ProfilerActivity<'a> {
167-
fn drop(&mut self) {
168-
let ProfilerActivity (category, profiler) = self;
169-
170-
profiler.end_activity(*category);
171-
}
172-
}
173-
174164
impl SelfProfiler {
175165
pub fn new() -> SelfProfiler {
176166
let mut profiler = SelfProfiler {
@@ -281,10 +271,4 @@ impl SelfProfiler {
281271

282272
fs::write("self_profiler_results.json", json).unwrap();
283273
}
284-
285-
pub fn record_activity<'a>(&'a mut self, category: ProfileCategory) -> ProfilerActivity<'a> {
286-
self.start_activity(category);
287-
288-
ProfilerActivity(category, self)
289-
}
290-
}
274+
}

0 commit comments

Comments
 (0)