Add std::__is_byte<std::byte> specialization

* include/bits/cpp_type_traits.h [__cplusplus >= 201703]
	(__is_byte<byte>): Define specialization for std::byte.

From-SVN: r262182
This commit is contained in:
Jonathan Wakely 2018-06-27 11:30:52 +01:00 committed by Jonathan Wakely
parent ed510b16a0
commit cd7ec27c3f
2 changed files with 14 additions and 0 deletions

View File

@ -1,5 +1,8 @@
2018-06-27 Jonathan Wakely <jwakely@redhat.com>
* include/bits/cpp_type_traits.h [__cplusplus >= 201703]
(__is_byte<byte>): Define specialization for std::byte.
PR libstdc++/86138
* include/bits/basic_string.tcc: [_GLIBCXX_EXTERN_TEMPLATE < 0]
Declare explicit instantiations of COW empty reps and I/O functions.

View File

@ -391,6 +391,17 @@ __INT_N(__GLIBCXX_TYPE_INT_N_3)
typedef __true_type __type;
};
#if __cplusplus >= 201703L
enum class byte : unsigned char;
template<>
struct __is_byte<byte>
{
enum { __value = 1 };
typedef __true_type __type;
};
#endif // C++17
//
// Move iterator type
//