Class destructor

Steven Taschuk staschuk at telusplanet.net
Fri Feb 14 15:54:27 EST 2003


Quoth Jp Calderone:
> On Thu, Feb 13, 2003 at 04:13:51PM -0700, Steven Taschuk wrote:
> > Quoth Jp Calderone:
  [...]
> > >   Actually, reference counting and garbage collection are two separate
> > > methods.  [...]
> > 
> > Um.  Reference counting is one type of garbage collection.  That
> > Python happens to have another kind of garbage collector as well
> > does not indicate otherwise, even though in Python-specific
> > contexts it is common to speak of the latter as "the" garbage
> > collector.
> 
>   What is comp.lang.python, if not a Python-specific contxt?

I see that I did not express myself very clearly.

"The garbage collector" means, in any context, "the salient
garbage collector in this context".  In a Python context, that's
the cyclic garbage collector.

"Garbage collection" means, in any context, processes or
mechanisms which collect garbage.  Even in a Python context, that
includes reference counting mechanisms.

So, if you say "reference counting is separate from what the
garbage collector does", I'll agree.  If you say "reference
counting is separate from garbage collection", I'll disagree,
since the former is just a special case of the latter.  If you say
I'm picking nits, well, you're not the first.

-- 
Steven Taschuk           |   7\ 7'Z {&~         .     St. George
staschuk at telusplanet.net |     Y r          --/hG-      &  the
                         | (__/ )_             1^1`     Dragon





More information about the Python-list mailing list