Disable the std::atomic spinlock implementation on Clang

This commit is contained in:
Peter Dimov
2014-03-01 02:14:56 +02:00
parent 75add10b1d
commit fbb851097f

View File

@ -32,7 +32,13 @@
#include <boost/smart_ptr/detail/sp_has_sync.hpp>
#if defined( BOOST_SP_USE_STD_ATOMIC )
# include <boost/smart_ptr/detail/spinlock_std_atomic.hpp>
# if !defined( __clang__ )
# include <boost/smart_ptr/detail/spinlock_std_atomic.hpp>
# else
// Clang (at least up to 3.4) can't compile spinlock_pool when
// using std::atomic, so substitute the __sync implementation instead.
# include <boost/smart_ptr/detail/spinlock_sync.hpp>
# endif
#elif defined( BOOST_SP_USE_PTHREADS )
# include <boost/smart_ptr/detail/spinlock_pt.hpp>