Re: Scope objects

2009-06-06 Thread Gabriel Genellina
En Sat, 06 Jun 2009 03:03:34 -0300, escribió: On Jun 5, 8:56 pm, Robert Dailey wrote: Is it possible to create an object in Python that will clean itself up at function exit? I realize destruction of objects may not occur immediately and can be garbage collected, but this functionality would

Re: Scope objects

2009-06-05 Thread s0suk3
On Jun 5, 8:56 pm, Robert Dailey wrote: > Is it possible to create an object in Python that will clean itself up > at function exit? I realize destruction of objects may not occur > immediately and can be garbage collected, but this functionality would > still be great to have. Consider the follow

Re: Scope objects

2009-06-05 Thread Robert Dailey
On Jun 5, 9:07 pm, Chris Rebert wrote: > On Fri, Jun 5, 2009 at 6:56 PM, Robert Dailey wrote: > > Is it possible to create an object in Python that will clean itself up > > at function exit? I realize destruction of objects may not occur > > immediately and can be garbage collected, but this funct

Re: Scope objects

2009-06-05 Thread Chris Rebert
On Fri, Jun 5, 2009 at 6:56 PM, Robert Dailey wrote: > Is it possible to create an object in Python that will clean itself up > at function exit? I realize destruction of objects may not occur > immediately and can be garbage collected, but this functionality would > still be great to have. Conside

Re: Scope objects

2009-06-05 Thread Stephen Hansen
On Fri, Jun 5, 2009 at 6:56 PM, Robert Dailey wrote: > Is it possible to create an object in Python that will clean itself up > at function exit? I realize destruction of objects may not occur > immediately and can be garbage collected, but this functionality would > still be great to have. Consi

Scope objects

2009-06-05 Thread Robert Dailey
Is it possible to create an object in Python that will clean itself up at function exit? I realize destruction of objects may not occur immediately and can be garbage collected, but this functionality would still be great to have. Consider the following function: def do_stuff(): foo = scope_ob