]> https://gitweb.dealii.org/ - dealii.git/commitdiff
indent
authorQuang Hoang <qxhmorrow@gmail.com>
Sat, 9 Dec 2023 19:48:00 +0000 (14:48 -0500)
committerQuang Hoang <qxhmorrow@gmail.com>
Sat, 9 Dec 2023 19:48:00 +0000 (14:48 -0500)
source/distributed/tria.cc

index 5bed5a4fd87057f58788f04deae18a4aeea605b2..9432f731ec3533acc09a3fa60a73e8686c8fcc28 100644 (file)
@@ -568,34 +568,35 @@ namespace
   void
   exchange_refinement_flags(Triangulation<dim, spacedim> &tria)
   {
-      // Communicate refinement flags on ghost cells from the owner of the
-      // cell. This is necessary to get consistent refinement, as mesh
-      // smoothing would undo some of the requested coarsening/refinement.
+    // Communicate refinement flags on ghost cells from the owner of the
+    // cell. This is necessary to get consistent refinement, as mesh
+    // smoothing would undo some of the requested coarsening/refinement.
+
+    auto pack =
+      [](
+        const typename Triangulation<dim, spacedim>::active_cell_iterator &cell)
+      -> std::uint8_t {
+      if (cell->refine_flag_set())
+        return 1;
+      if (cell->coarsen_flag_set())
+        return 2;
+      return 0;
+    };
+    auto unpack =
+      [](
+        const typename Triangulation<dim, spacedim>::active_cell_iterator &cell,
+        const std::uint8_t &flag) -> void {
+      cell->clear_coarsen_flag();
+      cell->clear_refine_flag();
+      if (flag == 1)
+        cell->set_refine_flag();
+      else if (flag == 2)
+        cell->set_coarsen_flag();
+    };
 
-      auto pack =
-        [](const typename Triangulation<dim, spacedim>::active_cell_iterator
-              &cell) -> std::uint8_t {
-        if (cell->refine_flag_set())
-          return 1;
-        if (cell->coarsen_flag_set())
-          return 2;
-        return 0;
-      };
-      auto unpack =
-        [](const typename Triangulation<dim, spacedim>::active_cell_iterator
-                              &cell,
-           const std::uint8_t &flag) -> void {
-        cell->clear_coarsen_flag();
-        cell->clear_refine_flag();
-        if (flag == 1)
-          cell->set_refine_flag();
-        else if (flag == 2)
-          cell->set_coarsen_flag();
-      };
-
-      GridTools::exchange_cell_data_to_ghosts<std::uint8_t,
-                                              Triangulation<dim, spacedim>>(
-        tria, pack, unpack);
+    GridTools::exchange_cell_data_to_ghosts<std::uint8_t,
+                                            Triangulation<dim, spacedim>>(
+      tria, pack, unpack);
   }
 
 #  ifdef P4EST_SEARCH_LOCAL
@@ -3277,7 +3278,6 @@ namespace parallel
     }
 
 
-    
 
     template <int dim, int spacedim>
     DEAL_II_CXX20_REQUIRES((concepts::is_valid_dim_spacedim<dim, spacedim>))

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.