http://gcc.gnu.org/bugzilla/show_bug.cgi?id=57926
Bug ID: 57926 Summary: Atomic functions broken with C++ but not C? Product: gcc Version: unknown Status: UNCONFIRMED Severity: major Priority: P3 Component: c++ Assignee: unassigned at gcc dot gnu.org Reporter: lailavrazda1979 at gmail dot com Note that this possible bug does not trigger with GCC, only G++. Try compiling the code in the attachment with g++. It'll give strange errors, including complaining that an argument must be a non-void pointer when it IS in fact, a non-void pointer.