@@ -63,6 +63,7 @@ _need_batch(_, ::Tuple{}, _) = false
63
63
64
64
need_batch_index (:: Union{Integer,UnitRange,Colon} , cs, _) = false , Base. tail (cs)
65
65
need_batch_index (i:: CartesianIndices{N} , cs, _) where N = false , last (splitcs (i, cs))
66
+ need_batch_index (i:: CartesianIndex{N} , cs, _) where N = false , last (splitcs (i,cs))
66
67
need_batch_index (:: StepRange , cs, :: ChunkStrategy{CanStepRange} ) = false , Base. tail (cs)
67
68
function need_batch_index (i, cs, batchstrat)
68
69
csnow, csrem = splitcs (i, cs)
159
160
splitcs (i:: AbstractArray{<:CartesianIndex} , cs) = splitcs (first (i). I, (), cs)
160
161
splitcs (i:: AbstractArray{Bool} , cs) = splitcs (size (i), (), cs)
161
162
splitcs (i:: CartesianIndices , cs) = splitcs (i. indices, (), cs)
163
+ splitcs (i:: CartesianIndex , cs) = splitcs (i. I,(),cs)
162
164
splitcs (_, cs) = (first (cs),), Base. tail (cs)
163
165
splitcs (si, csnow, csrem) = splitcs (Base. tail (si), (csnow... , first (csrem)), Base. tail (csrem))
164
166
splitcs (:: Tuple{} , csnow, csrem) = (csnow, csrem)
0 commit comments