stdcxx-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From far...@apache.org
Subject svn commit: r605539 - /incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp
Date Wed, 19 Dec 2007 13:44:55 GMT
Author: faridz
Date: Wed Dec 19 05:44:54 2007
New Revision: 605539

URL: http://svn.apache.org/viewvc?rev=605539&view=rev
Log:
2007-12-19 Farid Zaripov <farid_zaripov@epam.com>

	Merged r605537 from branches/4.2.x with a fix for STDCXX-585.
	* etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp: Don't define ~bad_alloc()
	when testing the presence of the other members to avoid multiply
	defined sybmol linker errors.

Modified:
    incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp

Modified: incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp
URL: http://svn.apache.org/viewvc/incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp?rev=605539&r1=605538&r2=605539&view=diff
==============================================================================
--- incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp (original)
+++ incubator/stdcxx/trunk/etc/config/src/BAD_ALLOC_ASSIGNMENT.cpp Wed Dec 19 05:44:54 2007
@@ -100,34 +100,29 @@
 
     virtual ~bad_alloc ();
 
-#  else   // if !defined (TEST_DTOR) 
-
-    ~bad_alloc () { }
-
-#    if defined (TEST_COPY_CTOR)
+#  elif defined (TEST_COPY_CTOR)
 
     bad_alloc (const bad_alloc&);
 
-#    elif defined (TEST_WHAT)
+#  elif defined (TEST_WHAT)
 
     virtual const char* what () const;
 
-#    else   // test assignment
+#  else   // test assignment
+
+#    if !defined (TEST_ASSIGNMENT)
+#      define TEST_ASSIGNMENT
+#    endif
+
+    bad_alloc& operator= (const bad_alloc&);
+
+    bad_alloc& assign (const bad_alloc &rhs) {
+        ++nassignments;
+        return *this = rhs;
+    }
 
-#      if !defined (TEST_ASSIGNMENT)
-#        define TEST_ASSIGNMENT
-#      endif
-
-      bad_alloc& operator= (const bad_alloc&);
-
-      bad_alloc& assign (const bad_alloc &rhs) {
-          ++nassignments;
-          return *this = rhs;
-      }
-
-#    endif   // TEXT_...
-#  endif   // !TEST_DTOR
-#endif   // !TEST_DEFAULT_COR
+#  endif   // TEST_...
+#endif   // !TEST_DEFAULT_CTOR
 
 };
 



Mime
View raw message