Skip to content

Commit 66be1c1

Browse files
committed
Fix VectorOfArrays and VectorOfVectors ctors
1 parent 3b5a1a2 commit 66be1c1

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/vector_of_arrays.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,12 +79,12 @@ end
7979

8080
export VectorOfArrays
8181

82-
function VectorOfArrays{T,N}(A::AbstractVector{AbstractArray{U,N}}) where {T,N,U}
82+
function VectorOfArrays{T,N}(A::AbstractVector{<:AbstractArray{U,N}}) where {T,N,U}
8383
R = VectorOfArrays{T,N}()
8484
append!(R, A)
8585
end
8686

87-
VectorOfArrays(A::AbstractVector{AbstractArray{T,N}}) where {T,N} = VectorOfArrays{T,N}(A)
87+
VectorOfArrays(A::AbstractVector{<:AbstractArray{T,N}}) where {T,N} = VectorOfArrays{T,N}(A)
8888

8989

9090
Base.convert(VA::Type{VectorOfArrays{T,N}}, A::AbstractVector{AbstractArray{U,N}}) where {T,N,U} = VA(A)
@@ -345,10 +345,10 @@ VectorOfVectors{T}() where {T} = VectorOfArrays{T,1}()
345345
VectorOfVectors(
346346
data::AbstractVector,
347347
elem_ptr::AbstractVector{Int},
348-
checks::Function = consistency_checks
348+
checks::Function = full_consistency_checks
349349
) = VectorOfArrays(
350350
data,
351351
elem_ptr,
352-
similar(A.elem_ptr, Dims{0}, size(elem_ptr, 1) - 1),
352+
similar(elem_ptr, Dims{0}, size(elem_ptr, 1) - 1),
353353
checks
354354
)

0 commit comments

Comments
 (0)