| 671 | |
| 672 | template <typename F> |
| 673 | inline auto with_data(F f) const |
| 674 | { |
| 675 | ASSERT(has_data()); |
| 676 | return switch_dtype(dtype(), [this, f]<typename T>() { |
| 677 | auto sp = data(); |
| 678 | auto d = base::span_cast<const T>(sp); |
| 679 | return f.template operator()<T>(d); |
| 680 | }); |
| 681 | } |
| 682 | |
| 683 | template <typename F> |
| 684 | inline auto with_numeric_data(F f) const |
nothing calls this directly
no test coverage detected