Skip to content

Commit

Permalink
swap alg_autodiff around
Browse files Browse the repository at this point in the history
  • Loading branch information
jClugstor committed Nov 12, 2024
1 parent f38cb2e commit f1f7a7a
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions lib/OrdinaryDiffEqDifferentiation/src/alg_utils.jl
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,14 @@ end

function alg_autodiff(alg)
autodiff = _alg_autodiff(alg)
if nameof(autodiff) == :AutoForwardDiff

if autodiff == Val{true}
return AutoForwardDiff()
elseif nameof(autodiff) == :AutoFiniteDiff
elseif autodiff == Val{false}
return AutoFiniteDiff()
elseif autodiff == Val{true}
elseif nameof(autodiff) == :AutoForwardDiff
return AutoForwardDiff()
elseif autodiff == Val{false}
elseif nameof(autodiff) == :AutoFiniteDiff
return AutoFiniteDiff()
end
end
Expand Down

0 comments on commit f1f7a7a

Please sign in to comment.