Message 144641 - Python tracker

Message144641

Author ncoghlan
Recipients Yury.Selivanov, eric.snow, meador.inge, ncoghlan
Date 2011-09-29.21:18:50
SpamBayes Score 0.014982536
Marked as misclassified No
Message-id <1317331131.14.0.42191726496.issue13062@psf.upfronthosting.co.za>
In-reply-to
Content
Huh, I didn't actually realise getclosure() could be written as a one liner until seeing Meador's version above:

  {var : cell.cell_contents for var, cell in zip(func.__code__.co_freevars, func.__closure__)}
History
Date User Action Args
2011-09-29 21:18:51ncoghlansetrecipients: + ncoghlan, meador.inge, Yury.Selivanov, eric.snow
2011-09-29 21:18:51ncoghlansetmessageid: <1317331131.14.0.42191726496.issue13062@psf.upfronthosting.co.za>
2011-09-29 21:18:50ncoghlanlinkissue13062 messages
2011-09-29 21:18:50ncoghlancreate