summaryrefslogtreecommitdiff
path: root/boost/chrono/io/time_point_io.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'boost/chrono/io/time_point_io.hpp')
-rw-r--r--boost/chrono/io/time_point_io.hpp18
1 files changed, 10 insertions, 8 deletions
diff --git a/boost/chrono/io/time_point_io.hpp b/boost/chrono/io/time_point_io.hpp
index 0cbc275c0e..ef51210bd8 100644
--- a/boost/chrono/io/time_point_io.hpp
+++ b/boost/chrono/io/time_point_io.hpp
@@ -34,20 +34,22 @@
#include <locale>
#include <ctime>
-#define BOOST_CHRONO_INTERNAL_TIMEGM \
- ( defined BOOST_WINDOWS && ! defined(__CYGWIN__) ) \
+#if ( defined BOOST_WINDOWS && ! defined(__CYGWIN__) ) \
|| (defined(sun) || defined(__sun)) \
|| (defined __IBMCPP__) \
|| defined __ANDROID__ \
|| defined __QNXNTO__ \
|| (defined(_AIX) && defined __GNUC__)
+#define BOOST_CHRONO_INTERNAL_TIMEGM
+#endif
-#define BOOST_CHRONO_INTERNAL_GMTIME \
- (defined BOOST_WINDOWS && ! defined(__CYGWIN__)) \
+#if (defined BOOST_WINDOWS && ! defined(__CYGWIN__)) \
|| ( (defined(sun) || defined(__sun)) && defined __GNUC__) \
|| (defined __IBMCPP__) \
|| defined __ANDROID__ \
|| (defined(_AIX) && defined __GNUC__)
+#define BOOST_CHRONO_INTERNAL_GMTIME
+#endif
#define BOOST_CHRONO_USES_INTERNAL_TIME_GET
@@ -746,7 +748,7 @@ namespace boost
namespace detail
{
-//#if BOOST_CHRONO_INTERNAL_TIMEGM
+//#if defined BOOST_CHRONO_INTERNAL_TIMEGM
inline int32_t is_leap(int32_t year)
{
@@ -949,7 +951,7 @@ namespace boost
}
else
{
-#if BOOST_CHRONO_INTERNAL_GMTIME
+#if defined BOOST_CHRONO_INTERNAL_GMTIME
if (detail::internal_gmtime(&t, &tm) == 0) failed = true;
#elif defined BOOST_WINDOWS && ! defined(__CYGWIN__)
@@ -1157,7 +1159,7 @@ namespace boost
if (err & std::ios_base::failbit) goto exit;
time_t t;
-#if BOOST_CHRONO_INTERNAL_TIMEGM
+#if defined BOOST_CHRONO_INTERNAL_TIMEGM
t = detail::internal_timegm(&tm);
#else
t = timegm(&tm);
@@ -1209,7 +1211,7 @@ namespace boost
time_t t;
if (tz == timezone::utc || fz != pe)
{
-#if BOOST_CHRONO_INTERNAL_TIMEGM
+#if defined BOOST_CHRONO_INTERNAL_TIMEGM
t = detail::internal_timegm(&tm);
#else
t = timegm(&tm);