Skip to content

Commit

Permalink
remove stale broadcasted_indices: (#1012)
Browse files Browse the repository at this point in the history
- referenced non-extant `indices`
- `broadcasted_indices` was deprecated to `broadcasted_axes` in JuliaLang/julia#25377
- `broadcasted_axes` was then replaced by plain `axes` JuliaLang/julia@a2feccf
- StaticArrays already has `axes` methods
  • Loading branch information
thchr committed Mar 14, 2022
1 parent 2976012 commit e35134c
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 3 deletions.
2 changes: 0 additions & 2 deletions src/broadcast.jl
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,6 @@ _bcs1(a::Base.OneTo, b::SOneTo) = _bcs1(a, Base.OneTo(b))
## Internal broadcast machinery for StaticArrays ##
###################################################

broadcast_indices(A::StaticArray) = indices(A)

# TODO: just use map(broadcast_size, as)?
@inline broadcast_sizes(a, as...) = (broadcast_size(a), broadcast_sizes(as...)...)
@inline broadcast_sizes() = ()
Expand Down
2 changes: 1 addition & 1 deletion test/broadcast.jl
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ end
# Issue #200: broadcast with Adjoint
@test @inferred(v1 .+ v2') === @SMatrix [2 5; 3 6]
@test @inferred(v1 .+ transpose(v2)) === @SMatrix [2 5; 3 6]
# Issue 382: infinite recursion in Base.Broadcast.broadcast_indices with Adjoint
# Issue 382: infinite recursion in broadcasting axes with Adjoint
@test @inferred(SVector(1,1)' .+ [1, 1]) == [2 2; 2 2]
@test @inferred(transpose(SVector(1,1)) .+ [1, 1]) == [2 2; 2 2]

Expand Down

0 comments on commit e35134c

Please sign in to comment.