Skip to content

Commit dbd42e0

Browse files
committed
change eachindex to LinearIndices
1 parent d83e39a commit dbd42e0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/OffsetArrays.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,7 @@ Base.eachindex(::IndexLinear, A::OffsetVector) = axes(A, 1)
241241
# We might not need this if the issue in Base is fixed, at that point we may impose an upper bound
242242
@inline function Base.compute_linindex(A::OffsetVector, I::NTuple{N,Any}) where N
243243
IP = Base.fill_to_length(axes(A), Base.OneTo(1), Val(N))
244-
Base.compute_linindex(first(eachindex(A)), 1, IP, I)
244+
Base.compute_linindex(first(LinearIndices(A)), 1, IP, I)
245245
end
246246

247247
Base.similar(A::OffsetArray, ::Type{T}, dims::Dims) where T =

0 commit comments

Comments
 (0)