]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Make one variable 'const'. 11492/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Thu, 7 Jan 2021 16:23:36 +0000 (09:23 -0700)
committerWolfgang Bangerth <bangerth@colostate.edu>
Thu, 7 Jan 2021 16:23:36 +0000 (09:23 -0700)
include/deal.II/fe/fe_point_evaluation.h

index deced7f9cad56248ccb12654b714c673e56f38ce..2a637cd27ccc477bb95d4de76408459b21b136af 100644 (file)
@@ -470,7 +470,7 @@ FEPointEvaluation<n_components, dim, spacedim>::evaluate(
   else if (values.size() > 0 || gradients.size() > 0)
     {
       // slow path with FEValues
-      UpdateFlags flags =
+      const UpdateFlags flags =
         (values.size() > 0 ? update_values : update_default) |
         (gradients.size() > 0 ? update_gradients : update_default);
       FEValues<dim, spacedim> fe_values(
@@ -480,6 +480,7 @@ FEPointEvaluation<n_components, dim, spacedim>::evaluate(
           std::vector<Point<dim>>(unit_points.begin(), unit_points.end())),
         flags);
       fe_values.reinit(cell);
+
       if (values.size() > 0)
         {
           AssertDimension(unit_points.size(), values.size());
@@ -503,6 +504,7 @@ FEPointEvaluation<n_components, dim, spacedim>::evaluate(
                       fe_values.shape_value_component(i, q, d) * value;
             }
         }
+
       if (gradients.size() > 0)
         {
           AssertDimension(unit_points.size(), gradients.size());

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.