From: Joel VanderWerf Date: 2008-03-19T02:41:41+09:00 Subject: Re: Thread#raise, Thread#kill, and timeout.rb are unsafe ara howard wrote: > > On Mar 14, 2008, at 8:42 AM, Yukihiro Matsumoto wrote: > >> Probably. Does anyone have any idea? > > > Thread.current.raises do |exception| > queue.push exception > end > > .... > > even_loop do > stuff > if exception = queue.pop > ... > end > end > > seems like it would address a ton of issued without overly complicating > ruby's internals - just provide an 'on raise' handler. Is it possible to integrate this with IO#select, so a thread can handle an exception sent to it while waiting on io? -- vjoel : Joel VanderWerf : path berkeley edu : 510 665 3407