C++ Logo

std-discussion

Advanced search

Re: No overload to create a span from a array<const T, X>

From: Lyberta <lyberta_at_[hidden]>
Date: Thu, 18 Jul 2019 20:50:00 +0000
Jean Guegant via Std-Discussion:
>> Makes me wonder why std::span ctor doesn't just take std::ContiguousRange.
>
> I assuming that the idea here is to make the span Extend template parameter
> being cross-checked against the array's size at compile-time instead of
> runtime. That's not necessarily a bad idea as long as it covers all sorts
> of array.
>
> Jean

Maybe we need another concept such as std::ConstexprSizedRange.


Received on 2019-07-18 15:52:16