MCPcopy Create free account
hub / github.com/bitfieldaudio/OTTO / ScopedTimer

Method ScopedTimer

src/util/timer.cpp:64–70  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

62 }
63
64 ScopedTimer::ScopedTimer(std::string id)
65 : id(id), start(time_point::clock::now())
66 {
67 auto& thread_timer = get_thread_timer();
68 parent = thread_timer.active_timer;
69 thread_timer.active_timer = this;
70 }
71
72 ScopedTimer::~ScopedTimer() {
73 auto duration = (time_point::clock::now() - start).count();

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected