From d592190a5b13b9760bb58504e5157dfe98594ca4 Mon Sep 17 00:00:00 2001 From: Wolfgang Bangerth Date: Tue, 27 Aug 2024 20:48:41 -0600 Subject: [PATCH] Make a condition easier to read. --- include/deal.II/lac/affine_constraints.templates.h | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/include/deal.II/lac/affine_constraints.templates.h b/include/deal.II/lac/affine_constraints.templates.h index 2f311b9e56..2e369db41f 100644 --- a/include/deal.II/lac/affine_constraints.templates.h +++ b/include/deal.II/lac/affine_constraints.templates.h @@ -659,11 +659,11 @@ AffineConstraints::make_consistent_in_parallel( this->add_constraint(line.index, line.entries, line.inhomogeneity); // 4) Stop loop if converged. - const auto constraints_converged = - Utilities::MPI::min(static_cast( - constraints_to_make_consistent == - constraints_made_consistent), - mpi_communicator); + const bool constraints_converged = + (Utilities::MPI::min( + (constraints_to_make_consistent == constraints_made_consistent ? 1 : + 0), + mpi_communicator) == 1); if (constraints_converged) break; } -- 2.39.5