Skip to content

Commit 617bd1d

Browse files
committed
move definitions later in the load sequence
1 parent 1113baa commit 617bd1d

File tree

3 files changed

+3
-6
lines changed

3 files changed

+3
-6
lines changed

base/multidimensional.jl

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1743,3 +1743,6 @@ function _sortslices(A::AbstractArray, d::Val{dims}; kws...) where dims
17431743
B
17441744
end
17451745
end
1746+
1747+
getindex(b::Ref, ::CartesianIndex{0}) = getindex(b)
1748+
setindex!(b::Ref, x, ::CartesianIndex{0}) = setindex!(b, x)

base/refpointer.jl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -117,9 +117,6 @@ cconvert(::Type{Ref{P}}, a::Array) where {P<:Union{Ptr,Cwstring,Cstring}} = Ref{
117117
###
118118

119119
getindex(b::RefArray) = b.x[b.i]
120-
getindex(b::RefArray, ::CartesianIndex{0}) = getindex(b)
121-
122120
setindex!(b::RefArray, x) = (b.x[b.i] = x; b)
123-
setindex!(b::RefArray, x, ::CartesianIndex{0}) = setindex!(b, x)
124121

125122
###

base/refvalue.jl

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,4 @@ end
3030
unsafe_convert(::Type{Ptr{Cvoid}}, b::RefValue{T}) where {T} = convert(Ptr{Cvoid}, unsafe_convert(Ptr{T}, b))
3131

3232
getindex(b::RefValue) = b.x
33-
getindex(b::RefValue, ::CartesianIndex{0}) = getindex(b)
34-
3533
setindex!(b::RefValue, x) = (b.x = x; b)
36-
setindex!(b::RefValue, x, ::CartesianIndex{0}) = setindex!(b, x)

0 commit comments

Comments
 (0)