diff --git a/DifferentiationInterface/ext/DifferentiationInterfaceForwardDiffExt/utils.jl b/DifferentiationInterface/ext/DifferentiationInterfaceForwardDiffExt/utils.jl index 8253077a1..d7ecbc576 100644 --- a/DifferentiationInterface/ext/DifferentiationInterfaceForwardDiffExt/utils.jl +++ b/DifferentiationInterface/ext/DifferentiationInterfaceForwardDiffExt/utils.jl @@ -2,7 +2,7 @@ choose_chunk(::AutoForwardDiff{nothing}, x) = Chunk(x) choose_chunk(::AutoForwardDiff{C}, x) where {C} = Chunk{min(length(x), C)}() tag_type(f, ::AutoForwardDiff{C,T}, x) where {C,T} = T -tag_type(f, ::AutoForwardDiff{C,Nothing}, x) where {C} = Tag{typeof(f),eltype(x)} +tag_type(f, ::AutoForwardDiff{C,Nothing}, x) where {C} = typeof(Tag(f, eltype(x))) make_dual_similar(::Type{T}, x::Number, dx::Number) where {T} = Dual{T}(x, dx) make_dual_similar(::Type{T}, x, dx) where {T} = similar(x, Dual{T,eltype(x),1})