C++26 introduces four targeted improvements to std::span. First, span<const T> can now be constructed from an initializer list, closing an ergonomic gap compared to string_view. Second, span gains a bounds-checked at() member function that throws std::out_of_range, bringing it in line with other standard containers. Third, span, mdspan, expected, out_ptr, and inout_ptr are added to the freestanding subset of the standard library (with at() excluded since it throws). Fourth, CTAD for both span and mdspan becomes integral_constant-aware, allowing the compiler to deduce static extents instead of always falling back to dynamic_extent.
Table of contents
P2447R6 : std::span over an initializer listP2821R5 : span.at()P2833R2 : Freestanding Library: inout expected spanP3029R1 : Better mdspan CTADConclusionConnect deeperSort: