From: Paul Brannan Date: 2002-04-27T01:19:03+09:00 Subject: Re: newbie: embedding ruby and garbage collection On Sat, Apr 27, 2002 at 12:49:36AM +0900, ts wrote: > Rather than register a callback, you can just create an object (with > Data_Wrap_struct) and store it in a Hash or Array (declared with > rb_global_variable()). > > When the instance of MyObject is destroyed, you just remove this object > from the hash (or the array). Will this also work with normal objects that are visible from Ruby? It would seem that this would speed up GC, since there are fewer objects to mark. Paul