From: Wolfgang Bangerth Date: Sat, 28 Oct 2023 18:33:45 +0000 (-0600) Subject: Rename a variable. X-Git-Tag: relicensing~346^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F16212%2Fhead;p=dealii.git Rename a variable. --- diff --git a/include/deal.II/lac/petsc_snes.templates.h b/include/deal.II/lac/petsc_snes.templates.h index 156dbc4cd4..8fe90971f0 100644 --- a/include/deal.II/lac/petsc_snes.templates.h +++ b/include/deal.II/lac/petsc_snes.templates.h @@ -641,19 +641,20 @@ namespace PETScWrappers AssertPETSc(status); // Get the number of steps taken. - PetscInt nt; - AssertPETSc(SNESGetIterationNumber(snes, &nt)); + PetscInt n_iterations; + AssertPETSc(SNESGetIterationNumber(snes, &n_iterations)); // Raise an exception if the solver has not converged SNESConvergedReason reason; AssertPETSc(SNESGetConvergedReason(snes, &reason)); AssertThrow(reason > 0, ExcMessage("SNES solver did not converge after " + - std::to_string(nt) + " iterations with reason " + + std::to_string(n_iterations) + + " iterations with reason " + SNESConvergedReasons[reason])); // Finally return - return nt; + return n_iterations; }