ArraysOfArrays.jl
ArraysOfArrays.jl copied to clipboard
sizehint! based on size of backing array
It is sometimes that case I'm constructing a VectorOfArrays and I know what size the backing array will be as well as the number of arrays they will constitute. Would it be useful to add a:
function Base.sizehint!(A::VectorOfArrays{T,N}, n, s::Int) where {T,N}
Overload for this situation? Happy to put together a PR if there's agreement this is helpful.
Sounds good - the question is, how do we express the size that we expect for the inner arrays in a way that fits the API of sizehint!?