Skip to content

Commit

Permalink
Merge pull request #195 from JuliaParallel/jb/11
Browse files Browse the repository at this point in the history
fix scalar view indexing for julia v1.1
  • Loading branch information
vchuravy authored Jan 1, 2019
2 parents 17b77d7 + 9a062ee commit e52ee78
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/darray.jl
Original file line number Diff line number Diff line change
Expand Up @@ -646,6 +646,9 @@ function Base.getindex(d::DArray, i::Int...)
end

Base.getindex(d::DArray) = d[1]
if VERSION > v"1.1-"
Base.getindex(d::SubDArray, I::Int...) = invoke(getindex, Tuple{SubArray{<:Any,N},Vararg{Int,N}} where N, d, I...)
end
Base.getindex(d::SubOrDArray, I::Union{Int,UnitRange{Int},Colon,Vector{Int},StepRange{Int,Int}}...) = view(d, I...)

function Base.isassigned(D::DArray, i::Integer...)
Expand Down

0 comments on commit e52ee78

Please sign in to comment.