| 567 | |
| 568 | template <typename InType, typename OutType> |
| 569 | inline void ConvertIntegerWithNulls(const PandasOptions& options, |
| 570 | const ChunkedArray& data, OutType* out_values) { |
| 571 | for (int c = 0; c < data.num_chunks(); c++) { |
| 572 | const auto& arr = *data.chunk(c); |
| 573 | const InType* in_values = GetPrimitiveValues<InType>(arr); |
| 574 | // Upcast to double, set NaN as appropriate |
| 575 | |
| 576 | for (int i = 0; i < arr.length(); ++i) { |
| 577 | *out_values++ = |
| 578 | arr.IsNull(i) ? static_cast<OutType>(NAN) : static_cast<OutType>(in_values[i]); |
| 579 | } |
| 580 | } |
| 581 | } |
| 582 | |
| 583 | template <typename T> |
| 584 | inline void ConvertIntegerNoNullsSameType(const PandasOptions& options, |
nothing calls this directly
no test coverage detected