Skip to content

Commit

Permalink
Apply suggestions from code review
Browse files Browse the repository at this point in the history
Co-authored-by: David Gardner <[email protected]>
  • Loading branch information
drreynolds and gardner48 authored Apr 27, 2024
1 parent 8549ed6 commit fa63d11
Show file tree
Hide file tree
Showing 8 changed files with 5 additions and 7 deletions.
2 changes: 1 addition & 1 deletion include/arkode/arkode_arkstep.h
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantType instead")
int ARKStepSetInterpolantType(void* arkode_mem, int itype);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int ARKStepSetInterpolantDegree(void* arkode_mem, int degree);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetDenseOrder instead")
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int ARKStepSetDenseOrder(void* arkode_mem, int dord);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetNonlinearSolver instead")
int ARKStepSetNonlinearSolver(void* arkode_mem, SUNNonlinearSolver NLS);
Expand Down
2 changes: 1 addition & 1 deletion include/arkode/arkode_erkstep.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantType instead")
int ERKStepSetInterpolantType(void* arkode_mem, int itype);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int ERKStepSetInterpolantDegree(void* arkode_mem, int degree);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetDenseOrder instead")
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int ERKStepSetDenseOrder(void* arkode_mem, int dord);
SUNDIALS_EXPORT int ERKStepSetTable(void* arkode_mem, ARKodeButcherTable B);
SUNDIALS_EXPORT int ERKStepSetTableNum(void* arkode_mem,
Expand Down
2 changes: 1 addition & 1 deletion include/arkode/arkode_mristep.h
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,7 @@ SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantType instead")
int MRIStepSetInterpolantType(void* arkode_mem, int itype);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int MRIStepSetInterpolantDegree(void* arkode_mem, int degree);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetDenseOrder instead")
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetInterpolantDegree instead")
int MRIStepSetDenseOrder(void* arkode_mem, int dord);
SUNDIALS_DEPRECATED_EXPORT_MSG("use ARKodeSetNonlinearSolver instead")
int MRIStepSetNonlinearSolver(void* arkode_mem, SUNNonlinearSolver NLS);
Expand Down
1 change: 1 addition & 0 deletions src/arkode/arkode.c
Original file line number Diff line number Diff line change
Expand Up @@ -558,6 +558,7 @@ int ARKodeWFtolerances(void* arkode_mem, ARKEwtFn efun)
return (ARK_MEM_NULL);
}
ark_mem = (ARKodeMem)arkode_mem;

if (ark_mem->MallocDone == SUNFALSE)
{
arkProcessError(ark_mem, ARK_NO_MALLOC, __LINE__, __func__, __FILE__,
Expand Down
1 change: 0 additions & 1 deletion src/arkode/arkode_erkstep_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ int ERKStepSetDenseOrder(void* arkode_mem, int dord)

int ERKStepSetInterpolantDegree(void* arkode_mem, int degree)
{
if (degree < 0) { degree = ARK_INTERP_MAX_DEGREE; }
return (ARKodeSetInterpolantDegree(arkode_mem, degree));
}

Expand Down
2 changes: 1 addition & 1 deletion src/arkode/arkode_ls.c
Original file line number Diff line number Diff line change
Expand Up @@ -1521,7 +1521,7 @@ int ARKodeSetMassPreconditioner(void* arkode_mem, ARKLsMassPrecSetupFn psetup,
/* Guard against use for time steppers that do not support mass matrices */
if (!ark_mem->step_supports_massmatrix)
{
arkProcessError(NULL, ARK_ILL_INPUT, __LINE__, __func__,
arkProcessError(ark_mem, ARK_ILL_INPUT, __LINE__, __func__,
__FILE__, "time-stepping module does not support non-identity mass matrices");
return (ARK_ILL_INPUT);
}
Expand Down
1 change: 0 additions & 1 deletion src/arkode/arkode_mristep_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,6 @@ int MRIStepGetWorkSpace(void* arkode_mem, long int* lenrw, long int* leniw)

int MRIStepSetInterpolantDegree(void* arkode_mem, int degree)
{
if (degree < 0) { degree = ARK_INTERP_MAX_DEGREE; }
return (ARKodeSetInterpolantDegree(arkode_mem, degree));
}

Expand Down
1 change: 0 additions & 1 deletion src/arkode/arkode_sprkstep_io.c
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,6 @@ int SPRKStepSetOrder(void* arkode_mem, int ord)

int SPRKStepSetInterpolantDegree(void* arkode_mem, int degree)
{
if (degree < 0) { degree = ARK_INTERP_MAX_DEGREE; }
return (ARKodeSetInterpolantDegree(arkode_mem, degree));
}

Expand Down

0 comments on commit fa63d11

Please sign in to comment.