Re: [Boost-bugs] [Boost C++ Libraries] #5431: compile error in Windows CE 6.0(interlocked)

Subject: Re: [Boost-bugs] [Boost C++ Libraries] #5431: compile error in Windows CE 6.0(interlocked)
From: Boost C++ Libraries (noreply_at_[hidden])
Date: 2012-08-09 20:00:21


#5431: compile error in Windows CE 6.0(interlocked)
--------------------------------------------------------+-------------------
  Reporter: Akira Takahashi <faithandbrave@…> | Owner: viboes
      Type: Bugs | Status: assigned
 Milestone: To Be Determined | Component: thread
   Version: Boost 1.46.1 | Severity: Problem
Resolution: | Keywords: wince interlocked
--------------------------------------------------------+-------------------

Comment (by mboard182@…):

 Replying to [comment:7 viboes]:
> Could changing the declarations to
>
>
> {{{
> extern "C" long __cdecl InterlockedIncrement( long volatile * );
> extern "C" long __cdecl InterlockedDecrement( long volatile * );
> extern "C" long __cdecl InterlockedCompareExchange( long volatile *,
 long, long );
> extern "C" long __cdecl InterlockedExchange( long volatile *, long );
> extern "C" long __cdecl InterlockedExchangeAdd( long volatile *, long );
> }}}
>
>
> solve also the issue?

 Yes, this appears to solve the link error. Can you help me understand
 why??

 AFAIK with 'extern "C"', the following have the same name (and indeed will
 not link for me on vc9.0/winCE6 arm)
 {{{
 void foo(int *i){...}
 void foo(volatile int *i){...}
 }}}

-- 
Ticket URL: <https://svn.boost.org/trac/boost/ticket/5431#comment:9>
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:10 UTC