]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Simplify even more 16751/head
authorMartin Kronbichler <martin.kronbichler@rub.de>
Fri, 15 Mar 2024 11:30:10 +0000 (12:30 +0100)
committerMartin Kronbichler <martin.kronbichler@rub.de>
Fri, 15 Mar 2024 11:30:10 +0000 (12:30 +0100)
include/deal.II/lac/vector.templates.h

index 21707800d5a267535dc542a4efba324a8a5dd332..139d7a6b691f6ffd611404e8319b6db0f3a92bc8 100644 (file)
@@ -1092,16 +1092,9 @@ Vector<Number>::do_reinit(const size_type new_size,
                           const bool      omit_zeroing_entries,
                           const bool      reset_partitioner)
 {
-  if (new_size == 0)
-    {
-      values.clear();
-    }
-  else
-    {
-      values.resize_fast(new_size);
-      if (!omit_zeroing_entries)
-        values.fill();
-    }
+  values.resize_fast(new_size);
+  if (!omit_zeroing_entries)
+    values.fill();
 
   if (reset_partitioner)
     maybe_reset_thread_partitioner();

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.