Skip to content

Commit

Permalink
Remove permutedims specialization for Diagonal (#151)
Browse files Browse the repository at this point in the history
* Remove permutedims specialization for Diagonal

* Limit method to older Julia versions
  • Loading branch information
jishnub authored Dec 14, 2023
1 parent a1580ce commit c794417
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/infrange.jl
Original file line number Diff line number Diff line change
Expand Up @@ -574,8 +574,9 @@ end

FillArrays._range_convert(::Type{AbstractVector{T}}, r::InfRanges) where T = convert(AbstractVector{T}, r)


permutedims(D::Diagonal{<:Any,<:InfRanges}) = D
if VERSION <= v"1.9"
permutedims(D::Diagonal{<:Any,<:InfRanges}) = D
end
copy(D::Diagonal{<:Any,<:InfRanges}) = D
broadcasted(::LazyArrayStyle{2}, ::typeof(*), a::Number, D::Diagonal{<:Any,<:InfRanges}) = a*D
broadcasted(::LazyArrayStyle{2}, ::typeof(*), D::Diagonal{<:Any,<:InfRanges}, a::Number) = D*a
Expand Down

0 comments on commit c794417

Please sign in to comment.