Skip to content

Commit 7f7ee11

Browse files
authored
Don't specify namespace for imported names (#363)
1 parent a1cab16 commit 7f7ee11

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/blockaxis.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ first(b::BlockedUnitRange) = b.first
259259
last(b::BlockedUnitRange)::Integer = isempty(blocklasts(b)) ? first(b)-1 : last(blocklasts(b))
260260

261261
# view and indexing are identical for a unitrange
262-
Base.view(b::BlockedUnitRange, K::Block{1}) = b[K]
262+
view(b::BlockedUnitRange, K::Block{1}) = b[K]
263263

264264
@propagate_inbounds function getindex(b::BlockedUnitRange, K::Block{1})
265265
k = Integer(K)

src/blockindices.jl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,12 @@ function Base.show(io::IO, B::Block{N,Int}) where N
114114
end
115115

116116
# Some views may be computed eagerly without the SubArray wrapper
117-
Base.@propagate_inbounds Base.view(r::AbstractRange, B::Block{1}) = r[to_indices(r, (B,))...]
118-
Base.@propagate_inbounds function Base.view(C::CartesianIndices{N}, b1::Block{1}, B::Block{1}...) where {N}
117+
@propagate_inbounds view(r::AbstractRange, B::Block{1}) = r[to_indices(r, (B,))...]
118+
@propagate_inbounds function view(C::CartesianIndices{N}, b1::Block{1}, B::Block{1}...) where {N}
119119
blk = Block((b1, B...))
120120
view(C, to_indices(C, (blk,))...)
121121
end
122-
Base.@propagate_inbounds function Base.view(C::CartesianIndices{N}, B::Block{N}) where {N}
122+
@propagate_inbounds function view(C::CartesianIndices{N}, B::Block{N}) where {N}
123123
view(C, to_indices(C, (B,))...)
124124
end
125125

@@ -310,7 +310,7 @@ _indices(B) = B
310310
show(io::IO, r::BlockSlice) = print(io, "BlockSlice(", r.block, ",", r.indices, ")")
311311

312312
# Avoid creating a SubArray wrapper in certain non-allocating cases
313-
Base.@propagate_inbounds Base.view(C::CartesianIndices{N}, bs::Vararg{BlockSlice,N}) where {N} = view(C, map(x->x.indices, bs)...)
313+
@propagate_inbounds view(C::CartesianIndices{N}, bs::Vararg{BlockSlice,N}) where {N} = view(C, map(x->x.indices, bs)...)
314314

315315
Block(bs::BlockSlice{<:BlockIndexRange}) = Block(bs.block)
316316

0 commit comments

Comments
 (0)