]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Update some uses of maybe unused 17532/head
authorRene Gassmoeller <rene.gassmoeller@mailbox.org>
Wed, 14 Aug 2024 22:47:58 +0000 (16:47 -0600)
committerRene Gassmoeller <rene.gassmoeller@mailbox.org>
Thu, 15 Aug 2024 17:04:06 +0000 (11:04 -0600)
source/distributed/tria.cc
source/grid/tria.cc

index 623822953dd93bddea365b047b3eb945bf0bea3f..6a28abc5a7ab019826cfdf4ee7b8925a0b0a3a03 100644 (file)
@@ -728,7 +728,7 @@ namespace
     typename internal::p4est::types<dim>::quadrant *quadrant,
     int /* rank_begin */,
     int /* rank_end */,
-    [[maybe_unused]] void * /* this is always nullptr */ point)
+    void * /* this is always nullptr */ point)
   {
     // point must be nullptr here
     Assert(point == nullptr, dealii::ExcInternalError());
@@ -1849,9 +1849,8 @@ namespace parallel
     template <int dim, int spacedim>
     DEAL_II_CXX20_REQUIRES((concepts::is_valid_dim_spacedim<dim, spacedim>))
     void Triangulation<dim, spacedim>::create_triangulation(
-      [[maybe_unused]] const TriangulationDescription::Description<dim,
-                                                                   spacedim>
-        &construction_data)
+      const TriangulationDescription::Description<dim, spacedim>
+        & /*construction_data*/)
     {
       DEAL_II_ASSERT_UNREACHABLE();
     }
@@ -2647,8 +2646,7 @@ namespace parallel
         // There must not be any chains!
         for (unsigned int i = 0; i < topological_vertex_numbering.size(); ++i)
           {
-            [[maybe_unused]] const unsigned int j =
-              topological_vertex_numbering[i];
+            const unsigned int j = topological_vertex_numbering[i];
             Assert(j == i || topological_vertex_numbering[j] == j,
                    ExcMessage("Got inconclusive constraints with chain: " +
                               std::to_string(i) + " vs " + std::to_string(j) +
@@ -3140,8 +3138,7 @@ namespace parallel
       // stores locally (in the future we should check that we have exactly as
       // many non-artificial cells as parallel_forest->local_num_quadrants)
       {
-        [[maybe_unused]] const unsigned int total_local_cells =
-          this->n_active_cells();
+        const unsigned int total_local_cells = this->n_active_cells();
 
 
         if (Utilities::MPI::n_mpi_processes(this->mpi_communicator) == 1)
index 09c2c41140af50564744f49b35be18297f95e195..fea4f7f3423695cec6ef75dc07b26e1ff46ddc25 100644 (file)
@@ -2007,9 +2007,9 @@ namespace internal
 
       // count the number of objects, of unused single objects and of
       // unused pairs of objects
-      [[maybe_unused]] unsigned int n_quads          = 0;
-      unsigned int                  n_unused_pairs   = 0;
-      unsigned int                  n_unused_singles = 0;
+      unsigned int n_quads          = 0;
+      unsigned int n_unused_pairs   = 0;
+      unsigned int n_unused_singles = 0;
       for (unsigned int i = 0; i < tria_faces.quads.used.size(); ++i)
         {
           if (tria_faces.quads.used[i])
@@ -2196,8 +2196,8 @@ namespace internal
      * should be called from the functions of the higher TriaLevel classes.
      */
     void
-    monitor_memory([[maybe_unused]] const TriaLevel   &tria_level,
-                   [[maybe_unused]] const unsigned int true_dimension)
+    monitor_memory(const TriaLevel   &tria_level,
+                   const unsigned int true_dimension)
     {
       Assert(2 * true_dimension * tria_level.refine_flags.size() ==
                tria_level.neighbors.size(),
@@ -2238,9 +2238,9 @@ namespace internal
 
           // count the number of objects, of unused single objects and of
           // unused pairs of objects
-          [[maybe_unused]] unsigned int n_objects        = 0;
-          unsigned int                  n_unused_pairs   = 0;
-          unsigned int                  n_unused_singles = 0;
+          unsigned int n_objects        = 0;
+          unsigned int n_unused_pairs   = 0;
+          unsigned int n_unused_singles = 0;
           for (unsigned int i = 0; i < tria_objects.used.size(); ++i)
             {
               if (tria_objects.used[i])

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.