]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Implement AffineConstraints::ConstraintLine::swap(). 15547/head
authorWolfgang Bangerth <bangerth@colostate.edu>
Fri, 30 Jun 2023 20:11:19 +0000 (14:11 -0600)
committerWolfgang Bangerth <bangerth@colostate.edu>
Fri, 30 Jun 2023 20:12:59 +0000 (14:12 -0600)
include/deal.II/lac/affine_constraints.h

index dc01b2cc468b437d601342da7f1b9c6bc1a38a52..71e8ad8220cd338aebe05513fa4f2898724f79b2 100644 (file)
@@ -1704,6 +1704,17 @@ public:
     {
       ar &index &entries &inhomogeneity;
     }
+
+    /**
+     * Swap function.
+     */
+    friend void
+    swap(ConstraintLine &l1, ConstraintLine &l2)
+    {
+      std::swap(l1.index, l2.index);
+      std::swap(l1.entries, l2.entries);
+      std::swap(l1.inhomogeneity, l2.inhomogeneity);
+    }
   };
 
   /**

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.