Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r75344 - trunk/libs/chrono/example
From: vicente.botet_at_[hidden]
Date: 2011-11-06 07:26:45


Author: viboes
Date: 2011-11-06 07:26:44 EST (Sun, 06 Nov 2011)
New Revision: 75344
URL: http://svn.boost.org/trac/boost/changeset/75344

Log:
Chrono: fix bad use of duration_style::prefix in IO V1
Text files modified:
   trunk/libs/chrono/example/french.cpp | 14 ++++----------
   1 files changed, 4 insertions(+), 10 deletions(-)

Modified: trunk/libs/chrono/example/french.cpp
==============================================================================
--- trunk/libs/chrono/example/french.cpp (original)
+++ trunk/libs/chrono/example/french.cpp 2011-11-06 07:26:44 EST (Sun, 06 Nov 2011)
@@ -9,19 +9,14 @@
 
 
 #include <boost/chrono/config.hpp>
-
-#if ! defined BOOST_CHRONO_USES_DURATION_PUT
-#undef BOOST_CHRONO_IO_V1_DONT_PROVIDE_DEPRECATED
-#undef BOOST_CHRONO_IO_USE_XALLOC
-#endif
-
 #include <boost/chrono/chrono_io.hpp>
 #include <boost/chrono/process_cpu_clocks.hpp>
 #include <boost/chrono/thread_clock.hpp>
 #include <iostream>
 #include <locale>
 
-#if defined BOOST_CHRONO_USES_DURATION_PUT
+
+#if defined BOOST_CHRONO_DONT_PROVIDE_DEPRECATED_IO_V1
 #include <boost/chrono/io/duration_units.hpp>
 
     using namespace boost;
@@ -112,13 +107,12 @@
     using namespace boost;
     using namespace boost::chrono;
 
-#if defined BOOST_CHRONO_USES_DURATION_PUT
+#if defined BOOST_CHRONO_DONT_PROVIDE_DEPRECATED_IO_V1
     cout.imbue(locale(locale(), new duration_units_fr<>()));
 #else
-
     cout.imbue(locale(locale(), new duration_punct<char>
         (
- duration_style::prefix,
+ duration_punct<char>::use_long,
             "secondes", "minutes", "heures",
             "s", "m", "h"
         )));


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