|
Boost : |
From: Peter Dimov (pdimov_at_[hidden])
Date: 2002-12-19 18:27:34
From: "Martin Schuerch" <mschuerch_at_[hidden]>
>
> "Peter Dimov" <pdimov_at_[hidden]> wrote in message
> news:002901c2a789$02a54960$1d00a8c0_at_pdimov2...
> > > extern "C" __declspec(dllimport) boost::detail::winapi::long_type
> > __stdcall
> > > InterlockedIncrement(boost::detail::winapi::long_type volatile *);
> > > extern "C" __declspec(dllimport) boost::detail::winapi::long_type
> > __stdcall
> > > InterlockedDecrement(boost::detail::winapi::long_type volatile *);
> > > extern "C" __declspec(dllimport) boost::detail::winapi::long_type
> > __stdcall
> > > InterlockedExchange(boost::detail::winapi::long_type volatile *,
> > > boost::detail::winapi::long_type);
> >
> > But won't these collide with the declarations in <windows.h>?
>
> No. I tried by including the widely used shared_ptr.hpp and windows.h (non
> 64 bit branch).
>
> Why should it, as long as the types exactly match the once in windows.h?
The problem is that only the more recent versions of <windows.h> have the
volatile qualifier in the declarations, and there seems to be no reliable
way to detect which <windows.h> is in use.
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk