Skip to content

Commit d04d4c8

Browse files
committed
Internal fix on _output_shape
1 parent d6ee359 commit d04d4c8

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/indexing.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -394,9 +394,9 @@ _ints2range_front(::Val{0}, ind, inds...) = ()
394394
_ints2range_front(::Val{0}) = ()
395395
# get output shape with given indices
396396
_output_shape(::CanonicalInt, inds...) = _output_shape(inds...)
397-
_output_shape(ind::AbstractRange, inds...) = (length(ind), _output_shape(inds...)...)
397+
_output_shape(ind::AbstractRange, inds...) = (Base.length(ind), _output_shape(inds...)...)
398398
_output_shape(::CanonicalInt) = ()
399-
_output_shape(x::AbstractRange) = (length(x),)
399+
_output_shape(x::AbstractRange) = (Base.length(x),)
400400
@inline function unsafe_get_collection(A::CartesianIndices{N}, inds) where {N}
401401
if (Base.length(inds) === 1 && N > 1) || stride_preserving_index(typeof(inds)) === False()
402402
return Base._getindex(IndexStyle(A), A, inds...)

0 commit comments

Comments
 (0)