diff --git a/libstdc++-v3/ChangeLog b/libstdc++-v3/ChangeLog index 0305de11d59..a0bee0e048a 100644 --- a/libstdc++-v3/ChangeLog +++ b/libstdc++-v3/ChangeLog @@ -1,3 +1,8 @@ +2018-02-20 François Dumont + + * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION] + (template<> __aligned_buffer): Define as __aligned_membuf alias. + 2018-02-19 Igor Tsimbalist PR target/84148 diff --git a/libstdc++-v3/include/ext/aligned_buffer.h b/libstdc++-v3/include/ext/aligned_buffer.h index 94a2ff0e67a..81fb797723c 100644 --- a/libstdc++-v3/include/ext/aligned_buffer.h +++ b/libstdc++-v3/include/ext/aligned_buffer.h @@ -75,6 +75,10 @@ namespace __gnu_cxx { return static_cast(_M_addr()); } }; +#if _GLIBCXX_INLINE_VERSION + template + using __aligned_buffer = __aligned_membuf<_Tp>; +#else // Similar to __aligned_membuf but aligned for complete objects, not members. // This type is used in , , // and , but ideally they would use __aligned_membuf @@ -113,6 +117,7 @@ namespace __gnu_cxx _M_ptr() const noexcept { return static_cast(_M_addr()); } }; +#endif } // namespace