Skip to content

Commit

Permalink
#2147: add documentation for added Trace functions
Browse files Browse the repository at this point in the history
  • Loading branch information
nmm0 committed May 16, 2023
1 parent 8835f53 commit f164f59
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/vt/trace/trace_lite.h
Original file line number Diff line number Diff line change
Expand Up @@ -252,10 +252,20 @@ struct TraceLite {
return static_cast<TimeIntegerType>(time * 1e6);
}

/**
* \brief Get the number of recorded trace events
*
* \return the number of trace events
*/
std::size_t getNumTraceEvents() const {
return traces_.size();
}

/**
* @brief Get the last recorded trace event
*
* @return the last recorded trace event
*/
const LogType* getLastTraceEvent() const noexcept {
return traces_.empty() ? nullptr : &traces_.back();
}
Expand Down

0 comments on commit f164f59

Please sign in to comment.