in reply to How can I call other objects from my object during DESTROY
I consider this to be a bug in Perl's "garbage collection", specifically the omniously named "global destruction" phase. During that phase, all remaining objects are destroying in a "convenient and efficient" order. That is, reference counts are ignored here.
So don't put any of your objects into global variables to avoid this problem.
Update: A pragma to request an extra step just before "global destruction" that would decrement the ref counts of all global variables by one and do any destruction trigger by that would also solve the problem with minimal impact to the Perl world.
- tye (but my friends call me "Tye")
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: (tye)Re: How can I call other objects from my object during DESTROY
by amackey (Beadle) on Jul 11, 2001 at 05:00 UTC | |
by tye (Sage) on Jul 11, 2001 at 05:44 UTC | |
by Anonymous Monk on Jul 11, 2001 at 06:05 UTC | |
by tye (Sage) on Jul 11, 2001 at 07:45 UTC | |
by dmmiller2k (Chaplain) on Jul 11, 2001 at 18:48 UTC |