10 May
2016
10 May
'16
8:33 a.m.
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.