[Bug libstdc++/60867] std::atomic<std::unique_ptr<T>> should fail to compile since unique_ptr is not trivial to copy

kjell.hedstrom at logrhythm dot com gcc-bugzilla@gcc.gnu.org
Thu Apr 17 14:06:00 GMT 2014


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=60867

--- Comment #2 from Kjell Hedstrom <kjell.hedstrom at logrhythm dot com> ---
Sounds good. 

>> the error is in your code not the library

Yes. Code like that is obviously faulty. I am happy that you are considering
putting in a static_assert. From a coders perspective I find it very helpful if
the compiler would immediately find bugs of this nature. 

Cheers
Kjell



More information about the Gcc-bugs mailing list