| 793 | } |
| 794 | |
| 795 | SEXP Allocate(R_xlen_t n) const { |
| 796 | // allocate a data frame column to host each array |
| 797 | // If possible, a column is dealt with directly with altrep |
| 798 | return AllocateDataFrame(n, [n](const std::shared_ptr<Converter>& converter) { |
| 799 | SEXP out = converter->MaybeAltrep(); |
| 800 | if (Rf_isNull(out)) { |
| 801 | out = converter->Allocate(n); |
| 802 | } |
| 803 | return out; |
| 804 | }); |
| 805 | } |
| 806 | |
| 807 | SEXP AllocateSlice(R_xlen_t n) const { |
| 808 | // altrep would shadow the whole chunked array rather than the slice |
nothing calls this directly
no test coverage detected