This will allocate the entire vector as a standard representation vector,
and store it in the data2
slot.
Note: this modifies x
in-place, so will modify any copies of x
, and
is irreversible.
Examples
x <- 1:3
compact_is_expanded(x)
#> [1] FALSE
compact_expand(x)
compact_is_expanded(x)
#> [1] TRUE