]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Avoid calling the constructor for emplace_back 8807/head
authorDaniel Arndt <arndtd@ornl.gov>
Fri, 20 Sep 2019 00:07:55 +0000 (18:07 -0600)
committerDaniel Arndt <arndtd@ornl.gov>
Fri, 20 Sep 2019 00:23:38 +0000 (18:23 -0600)
include/deal.II/lac/vector_memory.templates.h
source/base/parsed_convergence_table.cc
source/dofs/dof_handler_policy.cc

index 9e5df3160d03ee1bea6bcdf8ce73b2e625074e29..13934d112bec654cf30eef6e204d9653f7435db6 100644 (file)
@@ -132,8 +132,7 @@ GrowingVectorMemory<VectorType>::alloc()
     }
 
   // no free vector found, so let's just allocate a new one
-  get_pool().data->emplace_back(
-    entry_type(true, std_cxx14::make_unique<VectorType>()));
+  get_pool().data->emplace_back(true, std_cxx14::make_unique<VectorType>());
 
   return get_pool().data->back().second.get();
 }
index cb00e76f1c8a2b01a8a7d4c96dd1500b1ee0299b..cfcf8bca635dfa128b74d455c1ec653d3f798181 100644 (file)
@@ -48,10 +48,10 @@ namespace
     for (unsigned int i = 0; i < component_names.size(); ++i)
       {
         if (unique_component_names[j] != component_names[i])
-          masks.emplace_back(ComponentMask(bools[j++]));
+          masks.emplace_back(bools[j++]);
         bools[j][i] = true;
       }
-    masks.emplace_back(ComponentMask(bools[j++]));
+    masks.emplace_back(bools[j++]);
     AssertDimension(j, unique_component_names.size());
     return masks;
   }
index d47eda9007799350c266046b09854d57f2f22ff3..20726bb6e15098e13cfe71b4b0ea2b55a6b41919 100644 (file)
@@ -3476,7 +3476,7 @@ namespace internal
                 numbers::invalid_subdomain_id, *dof_handler, level);
 
             // then add a complete, sequential index set
-            number_caches.emplace_back(NumberCache(n_level_dofs));
+            number_caches.emplace_back(n_level_dofs);
           }
 
         const_cast<dealii::Triangulation<DoFHandlerType::dimension,

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.