2020-01-09 Jonathan Wakely <jwakely@redhat.com>
+ * include/ext/extptr_allocator.h (_ExtPtr_allocator::operator==)
+ (_ExtPtr_allocator::operator!=): Add missing const qualifiers.
+ * include/ext/pointer.h (readable_traits<_Pointer_adapter<S>>): Add
+ partial specialization to disambiguate the two constrained
+ specializations.
+
* include/experimental/type_traits (experimental::is_pod_v): Disable
-Wdeprecated-declarations warnings around reference to std::is_pod.
* include/std/type_traits (is_pod_v): Likewise.
template<typename _Up>
inline bool
- operator==(const _ExtPtr_allocator<_Up>& __rarg)
+ operator==(const _ExtPtr_allocator<_Up>& __rarg) const
{ return _M_real_alloc == __rarg._M_getUnderlyingImp(); }
inline bool
- operator==(const _ExtPtr_allocator& __rarg)
+ operator==(const _ExtPtr_allocator& __rarg) const
{ return _M_real_alloc == __rarg._M_real_alloc; }
template<typename _Up>
inline bool
- operator!=(const _ExtPtr_allocator<_Up>& __rarg)
+ operator!=(const _ExtPtr_allocator<_Up>& __rarg) const
{ return _M_real_alloc != __rarg._M_getUnderlyingImp(); }
inline bool
- operator!=(const _ExtPtr_allocator& __rarg)
+ operator!=(const _ExtPtr_allocator& __rarg) const
{ return _M_real_alloc != __rarg._M_real_alloc; }
template<typename _Up>
# include <bits/move.h>
# include <bits/ptr_traits.h>
#endif
+#if __cplusplus > 201703L
+# include <iterator> // for readable_traits
+#endif
namespace __gnu_cxx _GLIBCXX_VISIBILITY(default)
{
{ return pointer(std::addressof(__r)); }
};
+#if __cpp_lib_concepts
+ template<typename _Storage_policy>
+ struct readable_traits<__gnu_cxx::_Pointer_adapter<_Storage_policy>>
+ {
+ using value_type
+ = typename __gnu_cxx::_Pointer_adapter<_Storage_policy>::value_type;
+ };
+#endif
_GLIBCXX_END_NAMESPACE_VERSION
} // namespace
#endif