|
Boost : |
Subject: Re: [boost] BOOST_NO_CXX11_ATOMIC?
From: Rob Stewart (robertstewart_at_[hidden])
Date: 2013-12-01 06:43:45
On Nov 30, 2013, at 9:00 AM, "Peter Dimov" <lists_at_[hidden]> wrote:
> Beman Dawes wrote:
>> We have run into a similar situation with compilers initially providing only partial implementations of language features. For example, Microsoft only supporting unconditional noexcept. The de facto policy has been to define the macro (BOOST_NO_CXX11_HDR_ATOMIC) until the feature is complete. Anyone who wants to take advantage of a partial implementation can test for the particular compiler or library version involved.
+1
> That's not very useful in this case, because many uses of <atomic> don't need atomic structs. atomic<integral> and atomic<T*> cover a lot of ground. shared_ptr, for example, only needs atomic_int_least32_t.
Add feature macros and test for them. The macros can be defined when the header is fully supported or for particular compilers.
___
Rob
(Sent from my portable computation engine)
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk