|
Boost-Commit : |
Subject: [Boost-commit] svn:boost r68031 - trunk/boost/chrono
From: vicente.botet_at_[hidden]
Date: 2011-01-12 00:10:33
Author: viboes
Date: 2011-01-12 00:10:32 EST (Wed, 12 Jan 2011)
New Revision: 68031
URL: http://svn.boost.org/trac/boost/changeset/68031
Log:
Boost.Chrono: Move operator% to the lib extension's
Text files modified:
trunk/boost/chrono/config.hpp | 7 ++-----
trunk/boost/chrono/duration.hpp | 4 ++--
2 files changed, 4 insertions(+), 7 deletions(-)
Modified: trunk/boost/chrono/config.hpp
==============================================================================
--- trunk/boost/chrono/config.hpp (original)
+++ trunk/boost/chrono/config.hpp 2011-01-12 00:10:32 EST (Wed, 12 Jan 2011)
@@ -64,7 +64,8 @@
#undef BOOST_CHRONO_HAS_THREAD_CLOCK
#undef BOOST_CHRONO_THREAD_CLOCK_IS_STEADY
#endif
-// unicode support
+
+// unicode support ------------------------------//
#if defined(BOOST_NO_UNICODE_LITERALS) || defined(BOOST_NO_CHAR16_T) || defined(BOOST_NO_CHAR32_T)
//~ #define BOOST_CHRONO_HAS_UNICODE_SUPPORT
@@ -98,10 +99,6 @@
// enable dynamic linking on Windows ---------------------------------------//
-//# if (defined(BOOST_ALL_DYN_LINK) || defined(BOOST_CHRONO_DYN_LINK)) && defined(__BORLANDC__) && defined(__WIN32__)
-//# error Dynamic linking Boost.System does not work for Borland; use static linking instead
-//# endif
-
#ifdef BOOST_HAS_DECLSPEC // defined by boost.config
// we need to import/export our code only if the user has specifically
// asked for it by defining either BOOST_ALL_DYN_LINK if they want all boost
Modified: trunk/boost/chrono/duration.hpp
==============================================================================
--- trunk/boost/chrono/duration.hpp (original)
+++ trunk/boost/chrono/duration.hpp 2011-01-12 00:10:32 EST (Wed, 12 Jan 2011)
@@ -601,6 +601,7 @@
return CD(lhs).count() / CD(rhs).count();
}
+ #ifdef BOOST_CHRONO_EXTENSIONS
template <class Rep1, class Rep2, class Period>
inline
typename boost::disable_if <boost::chrono::detail::is_duration<Rep1>,
@@ -611,10 +612,9 @@
{
typedef typename common_type<Rep1, Rep2>::type CR;
duration<CR, Period> r = d;
- //return static_cast<CR>(r.count()) / static_cast<CR>(s);
return static_cast<CR>(s)/r.count();
}
-
+ #endif
// Duration %
template <class Rep1, class Period, class Rep2>
Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk