[issue12106] reflect syntatic sugar in with ast

Benjamin Peterson report at bugs.python.org
Wed May 25 03:27:32 CEST 2011


Benjamin Peterson <benjamin at python.org> added the comment:

2011/5/24 Nick Coghlan <report at bugs.python.org>:
>
> Nick Coghlan <ncoghlan at gmail.com> added the comment:
>
> Just to articulate the rationale, I'm guessing the reasoning behind this is to make it feasible for source->AST->source translators to retain the original grouping?

Correct. It also allows my Python static analysis tool to detect when
someone could be using the double with shorthand instead of
nested-withs.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue12106>
_______________________________________


More information about the Python-bugs-list mailing list