Skip to content

Commit e30af53

Browse files
committed
remove getindex method that only exists to reduce invalidation
the new method is slower
1 parent c0f8aef commit e30af53

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

base/abstractarray.jl

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1169,8 +1169,6 @@ function getindex(A::AbstractArray, I...)
11691169
error_if_canonical_getindex(IndexStyle(A), A, I...)
11701170
_getindex(IndexStyle(A), A, to_indices(A, I)...)
11711171
end
1172-
# To avoid invalidations from multidimensional.jl: getindex(A::Array, i1::Union{Integer, CartesianIndex}, I::Union{Integer, CartesianIndex}...)
1173-
getindex(A::Array, i1::Integer, I::Integer...) = A[to_indices(A, (i1, I...))...]
11741172

11751173
function unsafe_getindex(A::AbstractArray, I...)
11761174
@_inline_meta

0 commit comments

Comments
 (0)