Flowdock
kill(p1) public

Causes the given thread to exit (see Thread::exit).

   count = 0
   a = Thread.new { loop { count += 1 } }
   sleep(0.1)       #=> 0
   Thread.kill(a)   #=> #<Thread:0x401b3d30 dead>
   count            #=> 93947
   a.alive?         #=> false
Show source
Register or log in to add new notes.