| 162 | |
| 163 | template <typename offset_type> |
| 164 | int64_t SumOfListSizes(const ArraySpan& input) { |
| 165 | DCHECK(is_var_length_list(*input.type)); |
| 166 | const uint8_t* validity = input.buffers[0].data; |
| 167 | const auto* offsets = input.GetValues<offset_type>(1); |
| 168 | int64_t sum = 0; |
| 169 | arrow::internal::VisitSetBitRunsVoid( |
| 170 | validity, input.offset, input.length, |
| 171 | [&sum, offsets](int64_t run_start, int64_t run_length) { |
| 172 | sum += offsets[run_start + run_length + 1] - offsets[run_start]; |
| 173 | }); |
| 174 | return sum; |
| 175 | } |
| 176 | |
| 177 | template <typename offset_type> |
| 178 | int64_t SumOfListViewSizes(const ArraySpan& input) { |
nothing calls this directly
no test coverage detected