Skip to content

Commit

Permalink
[Numerics] Fix version check for SUNDIALS
Browse files Browse the repository at this point in the history
CVodeGetNumStepSolveFails is only defined in SUNDIALS 6.2 and up. Since the previous version check had a typo, this code was never included.

Closes #1771
  • Loading branch information
bryanwweber committed Aug 14, 2024
1 parent 5393a88 commit 9d28aa2
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/numerics/CVodesIntegrator.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -611,7 +611,7 @@ AnyMap CVodesIntegrator::solverStats() const
"supported with sundials versions less than 4.");
#endif

#if SUNDIALS_VERSION_MAJOR >= 6
#if SUNDIALS_VERSION_MAJOR >= 7 || (SUNDIALS_VERSION_MAJOR == 6 && SUNDIALS_VERSION_MINOR >= 2)
long int stepSolveFails = 0;
CVodeGetNumStepSolveFails(m_cvode_mem, &stepSolveFails);
stats["step_solve_fails"] = stepSolveFails;
Expand Down

0 comments on commit 9d28aa2

Please sign in to comment.