[Python-ideas] a new lambda syntax

Masklinn masklinn at masklinn.net
Mon Oct 19 23:04:46 CEST 2009

On 19 Oct 2009, at 22:50 , Ben Finney wrote:
> starwing <weasley_wx at qq.com> writes:
>> Oleg Broytman 写道:
>>> Single-line lambdas are good enough, and if you need more - just
>>> create a named function.
>> BUT, why we need a name? just to process something or make decide,
>> sometimes code itself is enough.
> When the code is more complex than a single expression, it's already
> complex enough that defining it first and then referring to it makes  
> for
> clearer code.
That sounds quite recursive. Is it a hard rule or are you allowed to  
write three consecutive statements or expressions in some cases?

More information about the Python-ideas mailing list