> On Mar 18, 2020, at 04:22, haael <ha...@interia.pl> wrote:
> 
> What is bugging me is the assymetry: there is a nice way to hint functions, 
> but there is none to hint loops.

Then Steve’s suggestion of a context manager seems perfect. It allows you to 
hint any statement, including a loop statement, by adding whatever code you 
want that gets run before and after the statement.
_______________________________________________
Python-ideas mailing list -- python-ideas@python.org
To unsubscribe send an email to python-ideas-le...@python.org
https://mail.python.org/mailman3/lists/python-ideas.python.org/
Message archived at 
https://mail.python.org/archives/list/python-ideas@python.org/message/6XOPENLTTFU5X5LV7UYPNBQEZJWZPDHW/
Code of Conduct: http://python.org/psf/codeofconduct/

Reply via email to