]> https://gitweb.dealii.org/ - dealii.git/commitdiff
MFTools::categorize_by_boundary_ids: use iterator 15441/head
authorPeter Munch <peterrmuench@gmail.com>
Thu, 22 Jun 2023 20:59:18 +0000 (22:59 +0200)
committerPeter Munch <peterrmuench@gmail.com>
Thu, 22 Jun 2023 20:59:18 +0000 (22:59 +0200)
include/deal.II/matrix_free/tools.h

index f83790bb16c66a0540e46e7414b6e6dbf6d889ff..a3b7ac947e8cb7a207f346528e07e35a35aa5f94 100644 (file)
@@ -378,13 +378,13 @@ namespace MatrixFreeTools
       unsigned int c_num = 0;
       for (unsigned int i = 0; i < GeometryInfo<dim>::faces_per_cell; ++i)
         {
-          auto &face = *cell->face(i);
-          if (face.at_boundary() && !cell->has_periodic_neighbor(i))
+          const auto face = cell->face(i);
+          if (face->at_boundary() && !cell->has_periodic_neighbor(i))
             c_num +=
               factors[i] * (1 + std::distance(bids.begin(),
                                               std::find(bids.begin(),
                                                         bids.end(),
-                                                        face.boundary_id())));
+                                                        face->boundary_id())));
         }
       return c_num;
     };

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.