Skip to content

Commit

Permalink
[core.time] refactored system_millis->time_millis and system_nanos->t…
Browse files Browse the repository at this point in the history
…ime_nanos
  • Loading branch information
harrand committed Nov 17, 2024
1 parent 16d5e6c commit 2e32fe9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions include/tz/core/time.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

namespace tz
{
std::uint64_t system_millis();
std::uint64_t system_nanos();
std::uint64_t time_millis();
std::uint64_t time_nanos();
}

#endif // TOPAZ_CORE_TIME_HPP
4 changes: 2 additions & 2 deletions src/tz/core/time.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@

namespace tz
{
std::uint64_t system_millis()
std::uint64_t time_millis()
{
return std::chrono::duration_cast<std::chrono::milliseconds>(std::chrono::steady_clock::now().time_since_epoch()).count();
}

std::uint64_t system_nanos()
std::uint64_t time_nanos()
{
return std::chrono::duration_cast<std::chrono::nanoseconds>(std::chrono::steady_clock::now().time_since_epoch()).count();
}
Expand Down

0 comments on commit 2e32fe9

Please sign in to comment.