At 11:42 -0500 11/26/02, Jesse Butler - Sun Microsystems wrote:
...Is there a way to use thrown Error's (from Error.pm) or die's from a thread? I want to die or throw, and then eval or catch in the main thread, but I keep getting these "failed to start" messages.This way we're never going to get any traffic on the ithreads mailing list... That's why I Cc'd the ithreads mailing list.
It looks like it used to say "died" and they changed it to "failed to start"... either way, my eval's and/or catch's are not working. Any ideas?
Actually, I haven't ever used Error.pm myself, let alone with threads.
If you want to communicate between threads (which is basically what you want), I see basically 2 possibilities:
1. Thread::Exit
Allows you to exit a thread anywhere and assign return values. This doesn't generate an event in the main thread, though.
2. Thread::Signal
If you're on Linux you might want to try this: it allows you to generate an event in the main thread from a piece of "catch" code.
Hope this helps.
Liz