A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-July/027032.html below:

[Python-Dev] patch: try/finally in generators

[Python-Dev] patch: try/finally in generators [Python-Dev] patch: try/finally in generatorsOren Tirosh oren-py-d@hishome.net
Mon, 29 Jul 2002 20:08:24 +0300
http://www.python.org/sf/584626

This patch removes the limitation of not allowing yield in the try part
of a try/finally. The dealloc function of a generator checks if the 
generator is still alive and resumes it one last time from the return 
instruction at the end of the code, causing any try/finally blocks to be 
triggered. Any exceptions raised are treated just like exceptions in a
__del__ finalizer (printed and ignored).

	Oren



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4