diff --git a/libcxx/include/span b/libcxx/include/span --- a/libcxx/include/span +++ b/libcxx/include/span @@ -343,13 +343,6 @@ _LIBCPP_INLINE_VISIBILITY constexpr reverse_iterator rbegin() const noexcept { return reverse_iterator(end()); } _LIBCPP_INLINE_VISIBILITY constexpr reverse_iterator rend() const noexcept { return reverse_iterator(begin()); } - _LIBCPP_INLINE_VISIBILITY constexpr void swap(span &__other) noexcept - { - pointer __p = __data; - __data = __other.__data; - __other.__data = __p; - } - _LIBCPP_INLINE_VISIBILITY span __as_bytes() const noexcept { return span{reinterpret_cast(data()), size_bytes()}; } @@ -509,17 +502,6 @@ _LIBCPP_INLINE_VISIBILITY constexpr reverse_iterator rbegin() const noexcept { return reverse_iterator(end()); } _LIBCPP_INLINE_VISIBILITY constexpr reverse_iterator rend() const noexcept { return reverse_iterator(begin()); } - _LIBCPP_INLINE_VISIBILITY constexpr void swap(span &__other) noexcept - { - pointer __p = __data; - __data = __other.__data; - __other.__data = __p; - - size_type __sz = __size; - __size = __other.__size; - __other.__size = __sz; - } - _LIBCPP_INLINE_VISIBILITY span __as_bytes() const noexcept { return {reinterpret_cast(data()), size_bytes()}; } @@ -544,12 +526,6 @@ -> enable_if_t, decltype(__s.__as_writable_bytes())> { return __s.__as_writable_bytes(); } -template -_LIBCPP_INLINE_VISIBILITY -constexpr void swap(span<_Tp, _Extent> &__lhs, span<_Tp, _Extent> &__rhs) noexcept -{ __lhs.swap(__rhs); } - - // Deduction guides template span(_Tp (&)[_Sz]) -> span<_Tp, _Sz>;