[Python-ideas] with *context_managers:

Ram Rachum ram.rachum at gmail.com
Sun Apr 1 22:25:41 CEST 2012

I'd like to be able to do this:

with *context_managers:
    pass # Some suite.

This is useful when you have an unknown number of context managers that you 
want to use. I currently use `contextlib.nested`, but I'd like the *star 
syntax much better.

What do you think?

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20120401/b7e42dfe/attachment.html>

More information about the Python-ideas mailing list