C++ Logo


Advanced search

Re: [std-proposals] Structured bindings for std::extents

From: Bernhard Manfred Gruber <bernhardmgruber_at_[hidden]>
Date: Mon, 8 May 2023 21:09:10 +0200

I would also be happy with just a "yeah, grab a paper number" or a
"no, makes no sense".

Thanks for the response!
Bernhard Manfred Gruber

On Mon, 20 Mar 2023 at 23:18, Bernhard Manfred Gruber
<bernhardmgruber_at_[hidden]> wrote:
> Hi!
> A colleague and I were playing around with `std::mdspan` and struggled
> to define generic algorithms that would work on mdspans of any
> dimension. We quickly needed the usual `std::make_index_sequence` etc.
> to iterate over the `std::extents` and the code was "not nice". The
> ergonomics would improve dramatically if we could somehow turn the
> `std::extents` directly into a pack of values. With P1061 (Structured
> Bindings can introduce a Pack), the only missing piece would be
> structured bindings on `std::extents`, which is what I would like to
> propose, backed by encouragement from some mdspan authors.
> Please find a corresponding draft with a small discussion attached. I
> am mainly looking for a first round of feedback, encouraging me to
> pursue this idea and get a paper number.
> Thank you for your feedback!
> Bernhard Manfred Gruber

Received on 2023-05-08 19:09:20