Skip to content

Commit b7f9c84

Browse files
committed
revert to old Base.similar behavior
1 parent a0770e4 commit b7f9c84

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/vector_of_array.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -712,7 +712,7 @@ Base.eltype(::Type{<:AbstractVectorOfArray{T}}) where {T} = T
712712
end
713713
end
714714
@inline function Base.similar(VA::VectorOfArray, ::Type{T} = eltype(VA)) where {T}
715-
VectorOfArray(similar.(Base.parent(VA), T))
715+
VectorOfArray([similar(VA[:, i], T) for i in eachindex(VA.u)])
716716
end
717717

718718
# for VectorOfArray with multi-dimensional parent arrays of arrays where all elements are the same type

0 commit comments

Comments
 (0)