MCPcopy Create free account
hub / github.com/InteractiveComputerGraphics/splashsurf / drop

Method drop

splashsurf_lib/src/profiling.rs:64–71  ·  view source on GitHub ↗
(&mut self)

Source from the content-addressed store, hash-verified

62/// Dropping a `Guard` will add its recorded elapsed time to the top of the current local scope stack
63impl Drop for Guard {
64 fn drop(&mut self) {
65 let duration = self.enter_time.elapsed();
66 PROFILER
67 .get()
68 .expect("Missing thread local profiler")
69 .write()
70 .leave(duration)
71 }
72}
73
74#[derive(Clone, Debug)]

Callers

nothing calls this directly

Calls 3

leaveMethod · 0.80
writeMethod · 0.80
getMethod · 0.45

Tested by

no test coverage detected