@@ -270,6 +270,7 @@ struct BlockSlice{BB,T<:Integer,INDS<:AbstractUnitRange{T}} <: AbstractUnitRange
270270end
271271
272272Block (bs:: BlockSlice{<:Block} ) = bs. block
273+ Block (bs:: BlockSlice{<:BlockIndexRange} ) = Block (bs. block)
273274
274275
275276for f in (:axes , :unsafe_indices , :axes1 , :first , :last , :size , :length ,
@@ -289,8 +290,6 @@ _indices(B) = B
289290# Avoid creating a SubArray wrapper in certain non-allocating cases
290291@propagate_inbounds view (C:: CartesianIndices{N} , bs:: Vararg{BlockSlice,N} ) where {N} = view (C, map (x-> x. indices, bs)... )
291292
292- Block (bs:: BlockSlice{<:BlockIndexRange} ) = Block (bs. block)
293-
294293"""
295294 NoncontiguousBlockSlice(blocks, indices)
296295
@@ -309,6 +308,7 @@ struct NoncontiguousBlockSlice{BB,T,INDS<:AbstractVector{T}} <: AbstractVector{T
309308end
310309
311310Block (bs:: NoncontiguousBlockSlice{<:Block} ) = bs. block
311+ Block (bs:: NoncontiguousBlockSlice{<:BlockIndexRange} ) = Block (bs. block)
312312
313313for f in (:axes , :unsafe_indices , :axes1 , :first , :last , :size , :length ,
314314 :unsafe_length , :start )
@@ -330,8 +330,6 @@ struct BlockRange{N,R<:NTuple{N,AbstractUnitRange{<:Integer}}} <: AbstractArray{
330330 BlockRange {N,R} (inds:: R ) where {N,R} = new {N,R} (inds)
331331end
332332
333- Block (bs:: NoncontiguousBlockSlice{<:BlockIndexRange} ) = Block (bs. block)
334-
335333# The following is adapted from Julia v0.7 base/multidimensional.jl
336334# definition of CartesianRange
337335
0 commit comments