Hello,

there's more to continuations+GC than meets the eye. On my system, the 
following program hogs memory real fast.

def foo
   loop do
     callcc do |cc|
       throw :up, [cc, proc {}]
     end.call
   end
end

cc, p = catch(:up) {foo}
cc.call(p)


If we replace "end.call" with just "end", memory is bounded. (It's 
weird, because the closure doesn't do anything, and should only 
capture the cc that was around when it was created.) There's something 
freaky about Ruby closures+continuations+GC, even without weakrefs.

Vladimir Slepnev

P.S. I sure hope that the letter will make it to ruby-core...