diff options
Diffstat (limited to '3rdParty/Boost/src/boost/chrono/duration.hpp')
-rw-r--r-- | 3rdParty/Boost/src/boost/chrono/duration.hpp | 19 |
1 files changed, 9 insertions, 10 deletions
diff --git a/3rdParty/Boost/src/boost/chrono/duration.hpp b/3rdParty/Boost/src/boost/chrono/duration.hpp index 97fe3d7..814adb0 100644 --- a/3rdParty/Boost/src/boost/chrono/duration.hpp +++ b/3rdParty/Boost/src/boost/chrono/duration.hpp @@ -414,13 +414,13 @@ struct common_type<chrono::duration<Rep1, Period1>, //----------------------------------------------------------------------------// namespace chrono { template <class Rep, class Period> - class duration + class BOOST_SYMBOL_VISIBLE duration { //BOOST_CHRONO_STATIC_ASSERT(boost::is_integral<Rep>::value, BOOST_CHRONO_A_DURATION_REPRESENTATION_MUST_BE_INTEGRAL, ()); BOOST_CHRONO_STATIC_ASSERT(!boost::chrono::detail::is_duration<Rep>::value, BOOST_CHRONO_A_DURATION_REPRESENTATION_CAN_NOT_BE_A_DURATION, ()); BOOST_CHRONO_STATIC_ASSERT(boost::ratio_detail::is_ratio<typename Period::type>::value, BOOST_CHRONO_SECOND_TEMPLATE_PARAMETER_OF_DURATION_MUST_BE_A_STD_RATIO, ()); @@ -430,16 +430,16 @@ namespace chrono { typedef Rep rep; typedef Period period; private: rep rep_; public: - BOOST_CONSTEXPR + BOOST_FORCEINLINE BOOST_CONSTEXPR duration() : rep_(duration_values<rep>::zero()) { } template <class Rep2> - BOOST_CONSTEXPR + BOOST_SYMBOL_VISIBLE BOOST_FORCEINLINE BOOST_CONSTEXPR explicit duration(const Rep2& r , typename boost::enable_if < mpl::and_ < boost::is_convertible<Rep2, rep>, mpl::or_ < treat_as_floating_point<rep>, @@ -449,23 +449,22 @@ namespace chrono { > > > >::type* = 0 ) : rep_(r) { } //~duration() {} //= default; - //BOOST_CONSTEXPR - //duration(const duration& rhs) : rep_(rhs.rep_) {} // = default; +// BOOST_CONSTEXPR duration(const duration& rhs) : rep_(rhs.rep_) {} // = default; duration& operator=(const duration& rhs) // = default; { if (&rhs != this) rep_= rhs.rep_; return *this; } // conversions template <class Rep2, class Period2> - BOOST_CONSTEXPR + BOOST_FORCEINLINE BOOST_CONSTEXPR duration(const duration<Rep2, Period2>& d , typename boost::enable_if < mpl::or_ < treat_as_floating_point<rep>, mpl::and_ < chrono_detail::is_evenly_divisible_by<Period2, period>, @@ -661,42 +660,42 @@ namespace chrono { namespace detail { template <class LhsDuration, class RhsDuration> struct duration_eq { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) + BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const { typedef typename common_type<LhsDuration, RhsDuration>::type CD; return CD(lhs).count() == CD(rhs).count(); } }; template <class LhsDuration> struct duration_eq<LhsDuration, LhsDuration> { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) + BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const { return lhs.count() == rhs.count(); } }; template <class LhsDuration, class RhsDuration> struct duration_lt { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) + BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const RhsDuration& rhs) const { typedef typename common_type<LhsDuration, RhsDuration>::type CD; return CD(lhs).count() < CD(rhs).count(); } }; template <class LhsDuration> struct duration_lt<LhsDuration, LhsDuration> { - BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) + BOOST_CONSTEXPR bool operator()(const LhsDuration& lhs, const LhsDuration& rhs) const { return lhs.count() < rhs.count(); } }; } // namespace detail |