From: Hal Fulton Date: 2003-09-05T11:45:41+09:00 Subject: Re: show me the ruby way Aredridel wrote: > Good use I can think of: > > hb3 = Hash.new { |h,k| > Thread.new { > some_task_with_immense_processing_that_assigns_to_h(h, k) > } > "incomplete" > } > > I can see that being used in the app I'm writing -- a clone of > Rhythmbox, which is a clone of iTunes -- I'd use it in the music-library > classes, where scanning the disk for music can take tens of minutes, but > the GUI is in it's own thread... I find this to be very clever. I'd want it to be commented, though, if I were reading the code. :) This snippet should perhaps be captured somewhere. Hal