[Python-Dev] curses/wrapper.py

Andrew Kuchling akuchlin@mems-exchange.org
Tue, 27 Jun 2000 14:20:21 -0400


On Wed, Jun 28, 2000 at 12:45:07AM +1000, Mark Hammond quoted:
>> Besides its redundancy, it also places the traceback into a
>> local variable
>> and then raises an exception -- a perfect recipe for creating a ref loop.

I think this is irrelevant for the curses.wrapper() function, which
simply restores the terminal state before re-raising the exception.
It probably won't ever be called repeatedly, making the question of a
memory leak moot.

Yes, I'd like to have wrapper() use Greg Stein's simpler and tidier
code.  Yes, I'd like to know why ESR claims the simpler version
doesn't work and have a replicable test case.  But right now there are
higher priority things to do, so I'm shelving this until after 1.6b1.
(Right now I'm trying to get the curses module compiling on Tru64, and
things don't look good.)

--amk