We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 0a9a57c commit 11b024fCopy full SHA for 11b024f
src/muladd.jl
@@ -366,9 +366,9 @@ end
366
BroadcastStyle(::Type{<:MulAdd}) = ApplyBroadcastStyle()
367
368
scalarone(::Type{T}) where T = one(T)
369
-scalarone(::Type{<:AbstractArray{T}}) where T = scalarone(T)
+scalarone(::Type{A}) where {A<:AbstractArray} = scalarone(eltype(A))
370
scalarzero(::Type{T}) where T = zero(T)
371
-scalarzero(::Type{<:AbstractArray{T}}) where T = scalarzero(T)
+scalarzero(::Type{A}) where {A<:AbstractArray} = scalarzero(eltype(A))
372
373
fillzeros(::Type{T}, ax) where T<:Number = Zeros{T}(ax)
374
mulzeros(::Type{T}, M) where T<:Number = fillzeros(T, axes(M))
0 commit comments