PR69301 don't assume atomic<T> can default construct T
authorJonathan Wakely <jwakely@redhat.com>
Wed, 18 Jan 2017 18:36:45 +0000 (18:36 +0000)
committerJonathan Wakely <redi@gcc.gnu.org>
Wed, 18 Jan 2017 18:36:45 +0000 (18:36 +0000)
commit2ae27b7076907aa872ffda98c4cb83b3dad30b40
tree90794a848af1e0d74bdf80751717721a84d17794
parent3083fc562eb49c1df94453a17f9dbc37462ab0d0
PR69301 don't assume atomic<T> can default construct T

PR libstdc++/69301
* include/std/atomic (atomic<T>::load, atomic<T>::exchange): Use
aligned buffer instead of default-initialized variable.
* testsuite/29_atomics/atomic/69301.cc: New test.
* include/experimental/memory (observer_ptr::release): Use reserved
name.
* include/ext/pointer.h (_Pointer_adapter::operator++(int))
(_Pointer_adapter::operator--(int)): Likewise.

From-SVN: r244588
libstdc++-v3/ChangeLog
libstdc++-v3/include/experimental/memory
libstdc++-v3/include/ext/pointer.h
libstdc++-v3/include/std/atomic
libstdc++-v3/testsuite/29_atomics/atomic/69301.cc [new file with mode: 0644]