Closed HDembinski closed 1 year ago
I think the span is missing something like this: https://github.com/boostorg/histogram/blob/develop/include/boost/histogram/detail/nonmember_container_access.hpp
and a corresponding ctor like this:
https://github.com/boostorg/histogram/blob/develop/include/boost/histogram/detail/span.hpp#L139
@glenfe Any progress on this and #125? I would like to move Histogram over to this span and drop my internal implementation, but I cannot until at least std::initializer_list is supported. I can add make_span myself.
Sorry for the delay @HDembinski. I'll finish both up this month, they'll be done for 1.82.0
Awesome, thanks!
Should be implemented on develop. Let me know if there are any issues using it in Histogram.
Thanks! Will do.
@HDembinski I've merged to master; I was waiting to see if you needed more functionality (e.g. support for std::valarray
) but there's still time to get that in.
Works perfectly thanks.
https://godbolt.org/z/be94ra9G3
In Boost Histogram, where I am trying to switch to boost/core/span.hpp now, I am seeing errors like this:
error: no viable conversion from 'const std::initializer_list<X>' to 'span<const X>'
. So it is fundamentally not an issue with the deduction guides.The old span that I had implemented internally for histogram supported this.