Skip to content

Commit

Permalink
Update src/FixedSizeArray.jl 1
Browse files Browse the repository at this point in the history
  • Loading branch information
nsajko authored Feb 5, 2025
1 parent e7a99f5 commit 2d92fb9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/FixedSizeArray.jl
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ for T ∈ (Vector, optional_memory...)
end

function check_ndims(::Type{FSA}, size::Tuple{Vararg{Integer}}) where {N, FSA <: (FixedSizeArray{E, N} where {E})}
if N != length(size)
if size isa Tuple{Vararg{Any, N}}
size
else
throw(DimensionMismatch("mismatch between dimension count in type and the length of the size tuple"))
end
end
Expand Down

0 comments on commit 2d92fb9

Please sign in to comment.