diff options
Diffstat (limited to 'libcxx/src/chrono.cpp')
-rw-r--r-- | libcxx/src/chrono.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/libcxx/src/chrono.cpp b/libcxx/src/chrono.cpp index 28cdb9de7a5..8c8e6b5d31a 100644 --- a/libcxx/src/chrono.cpp +++ b/libcxx/src/chrono.cpp @@ -12,7 +12,7 @@ #include "system_error" // __throw_system_error #include <time.h> // clock_gettime, CLOCK_MONOTONIC and CLOCK_REALTIME -#if defined(_WIN32) +#if defined(_LIBCPP_WIN32API) #define WIN32_LEAN_AND_MEAN #define VC_EXTRA_LEAN #include <Windows.h> @@ -22,13 +22,13 @@ #else #if !defined(CLOCK_REALTIME) #include <sys/time.h> // for gettimeofday and timeval -#endif -#endif +#endif // !defined(CLOCK_REALTIME) +#endif // defined(_LIBCPP_WIN32API) #if !defined(_LIBCPP_HAS_NO_MONOTONIC_CLOCK) #if __APPLE__ #include <mach/mach_time.h> // mach_absolute_time, mach_timebase_info_data_t -#elif !defined(_WIN32) && !defined(CLOCK_MONOTONIC) +#elif !defined(_LIBCPP_WIN32API) && !defined(CLOCK_MONOTONIC) #error "Monotonic clock not implemented" #endif #endif @@ -45,7 +45,7 @@ const bool system_clock::is_steady; system_clock::time_point system_clock::now() _NOEXCEPT { -#if defined(_WIN32) +#if defined(_LIBCPP_WIN32API) // FILETIME is in 100ns units using filetime_duration = _VSTD::chrono::duration<__int64, @@ -158,7 +158,7 @@ steady_clock::now() _NOEXCEPT return time_point(duration(fp())); } -#elif defined(_WIN32) +#elif defined(_LIBCPP_WIN32API) steady_clock::time_point steady_clock::now() _NOEXCEPT |