[Python-Dev] Re: [Patches] [Patch #101175] Fix slight bug in the Ref manual docs on listcomprehensions (original) (raw)

Ka-Ping Yee ping@lfw.org
Tue, 15 Aug 2000 23:23:57 -0700 (PDT)


On Wed, 16 Aug 2000, Greg Ewing wrote:

> [x if 6] should not be a legal expression but the grammar allows it today.

Why shouldn't it be legal? [...] Excluding it will make both the implementation and documentation more complicated, with no benefit that I can see.

I don't have a strong opinion on this either way, but i can state pretty confidently that the change would be tiny and simple: just replace "list_iter" in the listmaker production with "list_for", and you are done.

-- ?!ng

"I'm not trying not to answer the question; i'm just not answering it." -- Lenore Snell