From: Marc Fehling Date: Fri, 21 May 2021 19:34:14 +0000 (-0600) Subject: Fix clang-tidy issues with #12246. X-Git-Tag: v9.3.0-rc1~14^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=5508417bc42bd2fa61c6a3ceedfff17ecee313d3;p=dealii.git Fix clang-tidy issues with #12246. --- diff --git a/source/numerics/derivative_approximation.cc b/source/numerics/derivative_approximation.cc index 6b03c32d3b..d7d01a75a9 100644 --- a/source/numerics/derivative_approximation.cc +++ b/source/numerics/derivative_approximation.cc @@ -801,7 +801,11 @@ namespace DerivativeApproximation solution, component); // ...and the place where it lives - const Point this_center = fe_midpoint_value.quadrature_point(0); + // This needs to be a copy. If it was a reference, it would be changed + // after the next `reinit` call of the FEValues object. clang-tidy + // complains about this not being a reference, so we suppress the warning. + const Point this_center = + fe_midpoint_value.quadrature_point(0); // NOLINT // loop over all neighbors and // accumulate the difference