aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/include/std/span
diff options
context:
space:
mode:
Diffstat (limited to 'libstdc++-v3/include/std/span')
-rw-r--r--libstdc++-v3/include/std/span12
1 files changed, 6 insertions, 6 deletions
diff --git a/libstdc++-v3/include/std/span b/libstdc++-v3/include/std/span
index fb34940..24c61ba 100644
--- a/libstdc++-v3/include/std/span
+++ b/libstdc++-v3/include/std/span
@@ -38,8 +38,8 @@
#if __cplusplus > 201703L
-#include <type_traits>
#include <array>
+#include <cstddef>
#include <bits/stl_iterator.h>
#include <bits/ranges_base.h>
@@ -151,7 +151,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
constexpr
span() noexcept
requires ((_Extent + 1u) <= 1u)
- : _M_extent(0), _M_ptr(nullptr)
+ : _M_ptr(nullptr), _M_extent(0)
{ }
template<contiguous_iterator _It>
@@ -159,7 +159,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
constexpr explicit(extent != dynamic_extent)
span(_It __first, size_type __count)
noexcept
- : _M_extent(__count), _M_ptr(std::to_address(__first))
+ : _M_ptr(std::to_address(__first)), _M_extent(__count)
{
if constexpr (_Extent != dynamic_extent)
{
@@ -173,8 +173,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
constexpr explicit(extent != dynamic_extent)
span(_It __first, _End __last)
noexcept(noexcept(__last - __first))
- : _M_extent(static_cast<size_type>(__last - __first)),
- _M_ptr(std::to_address(__first))
+ : _M_ptr(std::to_address(__first)),
+ _M_extent(static_cast<size_type>(__last - __first))
{
if constexpr (_Extent != dynamic_extent)
{
@@ -392,8 +392,8 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
}
private:
- [[no_unique_address]] __detail::__extent_storage<extent> _M_extent;
pointer _M_ptr;
+ [[no_unique_address]] __detail::__extent_storage<extent> _M_extent;
};
// deduction guides