Author: faridz
Date: Wed Apr 9 11:25:51 2008
New Revision: 646469
URL: http://svn.apache.org/viewvc?rev=646469&view=rev
Log:
2008-04-09 Farid Zaripov <[EMAIL PROTECTED]>
* tests/diagnostics/19.std.exceptions.cpp (run_test): Use rw_warn()
instead of
rw_assert() on platforms where replacement new/delete operators can't
be defined.
Modified:
stdcxx/trunk/tests/diagnostics/19.std.exceptions.cpp
Modified: stdcxx/trunk/tests/diagnostics/19.std.exceptions.cpp
URL:
http://svn.apache.org/viewvc/stdcxx/trunk/tests/diagnostics/19.std.exceptions.cpp?rev=646469&r1=646468&r2=646469&view=diff
==============================================================================
--- stdcxx/trunk/tests/diagnostics/19.std.exceptions.cpp (original)
+++ stdcxx/trunk/tests/diagnostics/19.std.exceptions.cpp Wed Apr 9 11:25:51
2008
@@ -367,10 +367,27 @@
::operator delete (p);
new_throws = 0;
+#ifdef _RWSTD_NO_REPLACEABLE_NEW_DELETE
+
+ // MSVC and VAC++ don't reliably replace operators
+ // new and delete across shared librray boundaries
+
+ rw_warn (false, 0, __LINE__,
+ "replacement ::operator new(std::size_t = %u) failed "
+ "to throw when called directly from a program: this "
+ "is an expected failure on this platform",
+ sizeof long_str);
+
+#else // if !defined (_RWSTD_NO_REPLACEABLE_NEW_DELETE)
+
rw_assert (false, 0, __LINE__,
- "replacement ::operator new(std::size_t = %u) failed "
- "to throw when called directly from a program",
+ "replacement ::operator new(std::size_t = %u) "
+ "unexpectdly failed to throw when called directly "
+ "from a program",
sizeof long_str);
+
+#endif // _RWSTD_NO_REPLACEABLE_NEW_DELETE
+
}
_CATCH (...) {
new_throws = 1;