This PR reduces the use of push! in collect_with_eltype.
Unfortunately it's not as good as it could be, because we don't know the eltype of our iterator. Even when it is constant eltype(iter) is Any. It may be worth writing a custom iterator that keeps eltype.
This PR reduces the use of
push!
incollect_with_eltype
.Unfortunately it's not as good as it could be, because we don't know the eltype of our iterator. Even when it is constant
eltype(iter)
isAny
. It may be worth writing a custom iterator that keepseltype
.