[Python-ideas] Trial balloon: adding variable type declarations in support of PEP 484

Chris Angelico rosuav at gmail.com
Thu Aug 4 13:15:42 EDT 2016


On Fri, Aug 5, 2016 at 3:07 AM, אלעזר <elazarg at gmail.com> wrote:
> Just wanted to note that the typo
>
>   lamda: int
>
> Becomes syntactically correct. Maybe there are other similar problems.

True, but the correct version "lambda: int" wouldn't appear on a line
on its own, creating an anonymous function and then abandoning it.
It'll normally appear in a function call or similar, where you
wouldn't be allowed to type-declare a new variable.

ChrisA


More information about the Python-ideas mailing list