Boost logo

Boost :

Subject: Re: [boost] [lockfree] _ENABLE_ATOMIC_ALIGNMENT_FIX for VS 2015 Update 2
From: Tim Blechmann (tim_at_[hidden])
Date: 2016-05-10 04:33:09


> class tagged_index
> {
> public:
> typedef boost::uint16_t tag_t;
> typedef boost::uint16_t index_t;
>
> protected:
> index_t index;
> tag_t tag;
> };
>
>
> This is by design - your tagged_index has align 2, size 4, triggering the need for my atomic alignment fix.

boost lockfree ensure alignment of the atomics, so this warning is a
false positive. sending a warning is good and nice, but a compile error
is overkill imho. this code dates back before c++11 and still supports
c++03 compilers.

so yes, please make it a warning, but not an error.


Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk