Skip to content

Commit

Permalink
Add size(::LinearIndices) on older 0.7 versions
Browse files Browse the repository at this point in the history
  • Loading branch information
nalimilan committed Feb 4, 2018
1 parent 0b81558 commit 7b9463e
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/Compat.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1222,6 +1222,8 @@ end
@inbounds result = reshape(1:prod(dims), dims)[(I .- first.(iter.indices) .+ 1)...]
return result
end
elseif VERSION < v"0.7.0-DEV.3395"
Base.size(iter::LinearIndices{N,R}) where {N,R} = length.(iter.indices)
end


Expand Down

0 comments on commit 7b9463e

Please sign in to comment.