]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Use .empty() instead of .size()==0.
authorWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 10 Mar 2010 00:39:21 +0000 (00:39 +0000)
committerWolfgang Bangerth <bangerth@math.tamu.edu>
Wed, 10 Mar 2010 00:39:21 +0000 (00:39 +0000)
git-svn-id: https://svn.dealii.org/trunk@20776 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/lac/source/sparsity_tools.cc

index d402d872f23c878a5e27adcddacdf61c6e8048b0..d4e0e1aca25c152351c53c2ff00c7d9c3e27cb8c 100644 (file)
@@ -2,7 +2,7 @@
 //    $Id$
 //    Version: $Name$
 //
-//    Copyright (C) 2008, 2009 by the deal.II authors
+//    Copyright (C) 2008, 2009, 2010 by the deal.II authors
 //
 //    This file is subject to QPL and may not be  distributed
 //    without copyright and license information. Please refer
@@ -262,7 +262,7 @@ namespace SparsityTools
                                     // now if no valid points remain:
                                     // find dof with lowest coordination
                                     // number
-    if (last_round_dofs.size() == 0)
+    if (last_round_dofs.empty())
       last_round_dofs
        .push_back (internal::find_unnumbered_starting_index (sparsity,
                                                              new_indices));
@@ -318,7 +318,7 @@ namespace SparsityTools
                                         // components of the graph
                                         // that we would then have to
                                         // do next
-       if (next_round_dofs.size() == 0)
+       if (next_round_dofs.empty())
          {
            if (std::find (new_indices.begin(), new_indices.end(),
                           numbers::invalid_unsigned_int)
@@ -343,7 +343,7 @@ namespace SparsityTools
                                             // an error if we got
                                             // here and starting
                                             // indices were given
-           Assert (starting_indices.size() == 0,
+           Assert (starting_indices.empty(),
                    ExcMessage ("The input graph appears to have more than one "
                                "component, but as stated in the documentation "
                                "we only want to reorder such graphs if no "

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.