This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Eliminate uses of "sleep" in V3 testsuite


On Mon, Jan 03, 2005 at 06:07:13PM -0800, Mark Mitchell wrote:

> 2005-01-03  Mark Mitchell  <mark@codesourcery.com>
> 
> 	* testsuite/testsuite_hooks.cc: Use __throw_exception_again
> 	instead of just throw.

"__throw_exception_again;" should be used in place of "throw;" to rethrow
an active exception.  With -fno-exceptions __throw_exception_again is
replaced with an empty string, which is not what's wanted.

To throw a particular exception (rather than rethrowing an active
exception object) use the appropriate function, which in this case is
__throw_runtime_error(const char*)
i.e.
      __throw_runtime_error("could not initialize semaphore");

jon

-- 
"It is useless to attempt to reason a man out of a thing
 he was never reasoned into."
	- Jonathan Swift


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]