From: Guido Kanschat Date: Thu, 17 Mar 2005 00:13:31 +0000 (+0000) Subject: fix swap function X-Git-Tag: v8.0.0~14360 X-Git-Url: https://gitweb.dealii.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=aceb3e46b339acd8dd379c3a0462910cfc1abe4c;p=dealii.git fix swap function git-svn-id: https://svn.dealii.org/trunk@10176 0785d39b-7218-0410-832d-ea1e28bc413d --- diff --git a/deal.II/base/include/base/smartpointer.h b/deal.II/base/include/base/smartpointer.h index d37e2081c8..44e6486226 100644 --- a/deal.II/base/include/base/smartpointer.h +++ b/deal.II/base/include/base/smartpointer.h @@ -315,7 +315,13 @@ template inline void SmartPointer::swap (SmartPointer &tt) { - swap (t, tt.t); +#ifdef DEBUG + SmartPointer aux(t,id); + *this = tt; + tt = aux; +#else + std::swap (t, tt.t); +#endif }