[issue1941] 2.6 stdlib using with statement

Benjamin Peterson report at bugs.python.org
Sun Jan 27 19:58:17 CET 2008


Benjamin Peterson added the comment:

Today, I carefully looked through every change in my patching. I asked
myself "Does this do the same things in the same order as the original?"
and "Could exceptions cause the code to function differently?" They only
changes were when the block which used the file was not in a try finally
block so if an exception were raised, it the file would be closed. The
with statement of course removes this problem. So, I do believe the
patch is "semantically neutral." I would, however, not mind if another
set of eyes examined it.

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1941>
__________________________________


More information about the Python-bugs-list mailing list