Subject: [Boost-bugs] [Boost C++ Libraries] #5431: compile error in Windows CE 6.0(interlocked)
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2011-04-06 10:32:11
#5431: compile error in Windows CE 6.0(interlocked)
-------------------------------------------------------+--------------------
Reporter: Akira Takahashi <faithandbrave@â¦> | Owner: anthonyw
Type: Bugs | Status: new
Milestone: To Be Determined | Component: thread
Version: Boost 1.46.1 | Severity: Problem
Keywords: |
-------------------------------------------------------+--------------------
boost/detail/interlocked.hpp is compile error in Windows CE platform.
{{{
error C2733 : second C linkage of overloaded function 'InterlockedXXX' not
allowed
}}}
I correct follow change:
before
{{{
#elif defined(_WIN32_WCE)
// under Windows CE we still have old-style Interlocked* functions
extern "C" long __cdecl InterlockedIncrement( long* );
extern "C" long __cdecl InterlockedDecrement( long* );
extern "C" long __cdecl InterlockedCompareExchange( long*, long, long );
extern "C" long __cdecl InterlockedExchange( long*, long );
extern "C" long __cdecl InterlockedExchangeAdd( long*, long );
# define BOOST_INTERLOCKED_INCREMENT InterlockedIncrement
# define BOOST_INTERLOCKED_DECREMENT InterlockedDecrement
# define BOOST_INTERLOCKED_COMPARE_EXCHANGE InterlockedCompareExchange
# define BOOST_INTERLOCKED_EXCHANGE InterlockedExchange
# define BOOST_INTERLOCKED_EXCHANGE_ADD InterlockedExchangeAdd
}}}
after:
{{{
# define BOOST_INTERLOCKED_INCREMENT InterlockedIncrement
# define BOOST_INTERLOCKED_DECREMENT InterlockedDecrement
# define BOOST_INTERLOCKED_COMPARE_EXCHANGE InterlockedCompareExchange
# define BOOST_INTERLOCKED_EXCHANGE InterlockedExchange
# define BOOST_INTERLOCKED_EXCHANGE_ADD InterlockedExchangeAdd
}}}
-- Ticket URL: <https://svn.boost.org/trac/boost/ticket/5431> Boost C++ Libraries <http://www.boost.org/> Boost provides free peer-reviewed portable C++ source libraries.
This archive was generated by hypermail 2.1.7 : 2017-02-16 18:50:06 UTC