Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r84793 - in branches/release: boost/chrono/detail boost/chrono/io boost/chrono/io_v1 libs/chrono/doc libs/chrono/example libs/chrono/src libs/chrono/test libs/chrono/test/clock libs/chrono/test/duration libs/chrono/test/io libs/chrono/test/time_point libs/chrono/test/traits
From: vicente.botet_at_[hidden]
Date: 2013-06-15 06:36:41


Author: viboes
Date: 2013-06-15 06:36:41 EDT (Sat, 15 Jun 2013)
New Revision: 84793
URL: http://svn.boost.org/trac/boost/changeset/84793

Log:
Chrono: fix #8691,#8696 and update history.

Properties modified:
   branches/release/boost/chrono/detail/ (props changed)
   branches/release/boost/chrono/io/ (props changed)
   branches/release/boost/chrono/io_v1/ (props changed)
   branches/release/libs/chrono/example/ (props changed)
   branches/release/libs/chrono/src/ (props changed)
   branches/release/libs/chrono/test/clock/ (props changed)
   branches/release/libs/chrono/test/duration/ (props changed)
   branches/release/libs/chrono/test/io/ (props changed)
   branches/release/libs/chrono/test/time_point/ (props changed)
   branches/release/libs/chrono/test/traits/ (props changed)
   branches/release/libs/chrono/test/win32_test.cpp (props changed)
Text files modified:
   branches/release/boost/chrono/io/duration_get.hpp | 15 ++++++++++-----
   branches/release/boost/chrono/io/time_point_io.hpp | 5 ++++-
   branches/release/libs/chrono/doc/chrono.qbk | 9 ++++++---
   3 files changed, 20 insertions(+), 9 deletions(-)

Modified: branches/release/boost/chrono/io/duration_get.hpp
==============================================================================
--- branches/release/boost/chrono/io/duration_get.hpp Sat Jun 15 06:35:45 2013 (r84792)
+++ branches/release/boost/chrono/io/duration_get.hpp 2013-06-15 06:36:41 EDT (Sat, 15 Jun 2013) (r84793)
@@ -467,7 +467,7 @@
        * translation in other contexts, as e.g. days and weeks.
        *
        * @param facet the duration_units facet
- * @param s start input stream iterator.
+ * @param i start input stream iterator.
        * @param e end input stream iterator.
        * @param ios a reference to a ios_base.
        * @param err the ios_base state.
@@ -484,11 +484,14 @@
         const string_type* k = chrono_detail::scan_keyword(i, e, units, units_end,
         //~ std::use_facet<std::ctype<CharT> >(loc),
             err);
+ if (err & (std::ios_base::badbit | std::ios_base::failbit))
+ {
+ return i;
+ }
         if (!facet.match_n_d_valid_unit(k))
         {
           err |= std::ios_base::failbit;
         }
-
         return i;
       }
 
@@ -499,7 +502,7 @@
        * translation in other contexts, as e.g. days and weeks.
        *
        * @param facet the duration_units facet
- * @param s start input stream iterator.
+ * @param i start input stream iterator.
        * @param e end input stream iterator.
        * @param ios a reference to a ios_base.
        * @param err the ios_base state.
@@ -519,13 +522,15 @@
         const string_type* k = chrono_detail::scan_keyword(i, e, units, units_end,
         //~ std::use_facet<std::ctype<CharT> >(loc),
             err);
-
+ if (err & (std::ios_base::badbit | std::ios_base::failbit))
+ {
+ return i;
+ }
         if (!facet.match_valid_unit(k, rt))
         {
           err |= std::ios_base::failbit;
         }
         return i;
-
       }
     };
 

Modified: branches/release/boost/chrono/io/time_point_io.hpp
==============================================================================
--- branches/release/boost/chrono/io/time_point_io.hpp Sat Jun 15 06:35:45 2013 (r84792)
+++ branches/release/boost/chrono/io/time_point_io.hpp 2013-06-15 06:36:41 EDT (Sat, 15 Jun 2013) (r84793)
@@ -33,7 +33,10 @@
 #include <locale>
 #include <string.h>
 
-#define BOOST_CHRONO_INTERNAL_TIMEGM defined BOOST_WINDOWS && ! defined(__CYGWIN__)
+#define BOOST_CHRONO_INTERNAL_TIMEGM \
+ ( defined BOOST_WINDOWS && ! defined(__CYGWIN__) ) || \
+ ( (defined(sun) || defined(__sun)) && defined __GNUC__)
+
 #define BOOST_CHRONO_INTERNAL_GMTIME defined BOOST_WINDOWS && ! defined(__CYGWIN__)
 
 #define BOOST_CHRONO_USES_INTERNAL_TIME_GET

Modified: branches/release/libs/chrono/doc/chrono.qbk
==============================================================================
--- branches/release/libs/chrono/doc/chrono.qbk Sat Jun 15 06:35:45 2013 (r84792)
+++ branches/release/libs/chrono/doc/chrono.qbk 2013-06-15 06:36:41 EDT (Sat, 15 Jun 2013) (r84793)
@@ -9,13 +9,13 @@
 
 [library Boost.Chrono
     [quickbook 1.5]
- [version 2.0.0]
+ [version 2.0.2]
     [authors [Hinnant, Howard]]
     [authors [Dawes, Beman]]
     [authors [Botet Escriba, Vicente J.]]
     [copyright 2008 Howard Hinnant]
     [copyright 2006, 2008 Beman Dawes]
- [copyright 2009-2012 Vicente J. Botet Escriba]
+ [copyright 2009-2013 Vicente J. Botet Escriba]
     [category utilities system]
     [id chrono]
     [dirname chrono]
@@ -7324,7 +7324,7 @@
 [/==================================]
 
 [//////////////////////////////////////////////////////////////////////////////////////////////////////////////////////]
-[section [*Version 2.0.2, April 1, 2013 - 1.54] ]
+[section [*Version 2.0.2, June 15, 2013 - 1.54] ]
 
 [*Fixes:]
 
@@ -7333,6 +7333,9 @@
 * [@http://svn.boost.org/trac/boost/ticket/8367 #8367] chrono does not compile with clang from XCode 4.5.2 with -std=c++11 -stdlib=libc++ and -arch armv7
 * [@http://svn.boost.org/trac/boost/ticket/8370 #8370] typo in chrono reference
 * [@http://svn.boost.org/trac/boost/ticket/8435 #8435] Can't compile Chrono on HP-UX due to no CLOCK_REALTIME macro.
+* [@http://svn.boost.org/trac/boost/ticket/8690 #8690] duration_units_default - lost return types constness in overridden methods.
+* [@http://svn.boost.org/trac/boost/ticket/8691 #8691] iostate is not checked after scan_keyword call.
+* [@http://svn.boost.org/trac/boost/ticket/8696 #8696] chrono compilation error on Solaris/gcc.
 
 [endsect] [/section [*Version 2.0.2] ]
 


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