Skip to content

Commit

Permalink
fix: get element type from interp.u instead of interp
Browse files Browse the repository at this point in the history
  • Loading branch information
sathvikbhagavan committed May 31, 2024
1 parent 7db42de commit 0467576
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/DataInterpolations.jl
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ include("show.jl")
(interp::AbstractInterpolation)(t::Number) = _interpolate(interp, t)
(interp::AbstractInterpolation)(t::Number, i::Integer) = _interpolate(interp, t, i)
function (interp::AbstractInterpolation)(t::AbstractVector)
interp(similar(t, promote_type(eltype(interp), eltype(t))), t)
interp(similar(t, promote_type(eltype(interp.u), eltype(t))), t)
end
function (interp::AbstractInterpolation)(u::AbstractVector, t::AbstractVector)
iguess = firstindex(interp.t)
Expand Down

0 comments on commit 0467576

Please sign in to comment.