Jamie Willis wrote:
What about just supporting filtering syntax at the top level?
for x range(50) if x % 2: print(x)
It would be more general and probably easier to support this:
for x in range(50): if x % 2: print(x)
i.e. just relax the requirement that a statement following
on the same line after a colon must be a simple statement.
--
Greg
_______________________________________________
Python-ideas mailing list
Python-ideas@python.org
https://mail.python.org/mailman/listinfo/python-ideas
Code of Conduct: http://python.org/psf/codeofconduct/