From acb880d8c2c19864a6176da78aca0935b0eccb7d Mon Sep 17 00:00:00 2001 From: Edward Diener Date: Wed, 22 Jul 2015 06:51:49 -0400 Subject: [PATCH] Change to Sleep declaration for clang on Windows to match Windows implementation being used --- include/boost/smart_ptr/detail/yield_k.hpp | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/include/boost/smart_ptr/detail/yield_k.hpp b/include/boost/smart_ptr/detail/yield_k.hpp index c3d0450..5beefd6 100644 --- a/include/boost/smart_ptr/detail/yield_k.hpp +++ b/include/boost/smart_ptr/detail/yield_k.hpp @@ -27,6 +27,10 @@ #include #include +#if defined __MINGW32__ +#include <_mingw.h> +#endif + #if BOOST_PLAT_WINDOWS_RUNTIME #include #endif @@ -60,10 +64,10 @@ namespace detail { #if !defined( BOOST_USE_WINDOWS_H ) && !BOOST_PLAT_WINDOWS_RUNTIME -#if BOOST_COMP_CLANG - extern "C" __declspec(dllimport) void __stdcall Sleep( unsigned long ms ); -#else +#if !BOOST_COMP_CLANG || (defined __MINGW32__ && !defined __MINGW64_VERSION_MAJOR) extern "C" void __stdcall Sleep( unsigned long ms ); +#else + extern "C" __declspec(dllimport) void __stdcall Sleep( unsigned long ms ); #endif #endif