From: Wolfgang Bangerth Date: Fri, 30 Jun 2023 20:11:19 +0000 (-0600) Subject: Implement AffineConstraints::ConstraintLine::swap(). X-Git-Tag: relicensing~835^2 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e3718b16cf187b77c91c7ae915986cd96919833e;p=dealii.git Implement AffineConstraints::ConstraintLine::swap(). --- diff --git a/include/deal.II/lac/affine_constraints.h b/include/deal.II/lac/affine_constraints.h index dc01b2cc46..71e8ad8220 100644 --- a/include/deal.II/lac/affine_constraints.h +++ b/include/deal.II/lac/affine_constraints.h @@ -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); + } }; /**