aligned_buffer.h [...] (template<> __aligned_buffer): Define as __aligned_membuf...
authorFrançois Dumont <fdumont@gcc.gnu.org>
Tue, 20 Feb 2018 20:51:44 +0000 (20:51 +0000)
committerFrançois Dumont <fdumont@gcc.gnu.org>
Tue, 20 Feb 2018 20:51:44 +0000 (20:51 +0000)
2018-02-20  François Dumont  <fdumont@gcc.gnu.org>

* include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
(template<> __aligned_buffer): Define as __aligned_membuf alias.

From-SVN: r257861

libstdc++-v3/ChangeLog
libstdc++-v3/include/ext/aligned_buffer.h

index 0305de1..a0bee0e 100644 (file)
@@ -1,3 +1,8 @@
+2018-02-20  François Dumont  <fdumont@gcc.gnu.org>
+
+       * include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
+       (template<> __aligned_buffer): Define as __aligned_membuf alias.
+
 2018-02-19  Igor Tsimbalist  <igor.v.tsimbalist@intel.com>
 
        PR target/84148
index 94a2ff0..81fb797 100644 (file)
@@ -75,6 +75,10 @@ namespace __gnu_cxx
       { return static_cast<const _Tp*>(_M_addr()); }
     };
 
+#if _GLIBCXX_INLINE_VERSION
+  template<typename _Tp>
+    using __aligned_buffer = __aligned_membuf<_Tp>;
+#else
   // Similar to __aligned_membuf but aligned for complete objects, not members.
   // This type is used in <forward_list>, <future>, <bits/shared_ptr_base.h>
   // and <bits/hashtable_policy.h>, but ideally they would use __aligned_membuf
@@ -113,6 +117,7 @@ namespace __gnu_cxx
       _M_ptr() const noexcept
       { return static_cast<const _Tp*>(_M_addr()); }
     };
+#endif
 
 } // namespace