From: Roger Pack Date: 2012-06-27T02:13:42+09:00 Subject: [ruby-core:45890] Re: [ruby-trunk - Bug #6614] GC doesn't collect objects bound to (collectable) proc > Your code uses `print' but not `printf', so the arguments cannot be optimized out, even if necessary assumptions are all met. > A possibility would be JRuby calls finalizers *BEFORE* the destruction. > What's printed in JRuby? runcollector runcollector so it still has a reference to the old object. Which way seems more sane somehow, but is probably wrong. I suppose my gripe is more that define_finalizer too many times creates proc's that are essentially "orphaned" but cannot be collected, which is basically a memory leak waiting to happen. Cheers! -r