summaryrefslogtreecommitdiffhomepage
path: root/compat/time.hpp
diff options
context:
space:
mode:
authorStanislaw Halik <sthalik@misaki.pl>2018-03-10 19:08:03 +0100
committerStanislaw Halik <sthalik@misaki.pl>2018-03-10 19:08:03 +0100
commitbc7c4cb72790ff7f64917cdb63f9b6c209c75384 (patch)
treea5e0a4407e15dddfad6df39320141c9159841b59 /compat/time.hpp
parent958b2c1bed7603dd0eb16c2a403ab9efd8e6b20f (diff)
compat/time{,r}: get rid of `long long'
Diffstat (limited to 'compat/time.hpp')
-rw-r--r--compat/time.hpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/compat/time.hpp b/compat/time.hpp
index d34e4e8c..c246a9e5 100644
--- a/compat/time.hpp
+++ b/compat/time.hpp
@@ -8,7 +8,7 @@ template<typename repr, typename ratio = std::ratio<1>>
using duration = std::chrono::duration<repr, ratio>;
template<typename t, typename u>
-static inline constexpr auto time_cast(const u& in)
+static inline constexpr auto time_cast(u&& in)
{
return std::chrono::duration_cast<t>(in);
}
@@ -17,7 +17,6 @@ using secs = duration<double>;
using secs_ = duration<long>;
using ms = duration<double, std::milli>;
using us = duration<double, std::micro>;
-using us_ = duration<long long, std::micro>;
-using ns = duration<long long, std::nano>;
+using ns = duration<double, std::nano>;
} // ns time_units