On 7 December 2011 23:58, Benjamin Kosnik wrote:
>
>> * include/bits/atomic_base.h (__calculate_memory_order):
>> Rename to... (__cmpexch_failure_order): This, and rewrite as
>> constexpr function. (compare_exchange_strong, compare_exchange_weak):
>> Use it.
>> * include/std/atomic
> * include/bits/atomic_base.h (__calculate_memory_order):
> Rename to... (__cmpexch_failure_order): This, and rewrite as
> constexpr function. (compare_exchange_strong, compare_exchange_weak):
> Use it.
> * include/std/atomic (compare_exchange_strong,
> compare_exchange_weak): Lik
Are there any objections to this patch?
I find the function easier to parse in this form and it allows it to
be constexpr. Maybe more importantly, it determines the memory order
to be used by compare_exchange_xxx on failure so I think
__cmpexch_failure_order is a more descriptive name than
__calcu