[Python-3000] Requiring () around lambda's argument list

Guido van Rossum guido at python.org
Tue May 2 16:51:19 CEST 2006


On 5/2/06, Michael Chermside <mcherm at mcherm.com> wrote:
> Thomas Wouters writes:
> > Lambda-lovers will probably jump all over me for suggesting
> > this, and I doubt you'll go fir it, but what about just not
> > allowing type annotations in lambda statements? They're
> > neutered anyway.
>
> Speaking as a lambda user... +1... Great Idea Thomas! Lambdas are
> for tiny anonymous functions... if you feel the need to specify the
> types, why not go ahead and include a function name and perhaps
> even a docstring -- use def instead.

Fine with me -- this is in fact the solution I was going to prototype.
But in the long run I expect the difference is going to grate.
Later...

--
--Guido van Rossum (home page: http://www.python.org/~guido/)


More information about the Python-3000 mailing list