[Python-ideas] Ruby-style Blocks in Python Idea
jimjjewett at gmail.com
Tue Mar 10 23:05:02 CET 2009
On 3/10/09, Terry Reedy <tjreedy at udel.edu> wrote:
> ... I dislike the silly claim that
> being named '<lambda>' is a virtue. And this was in the context you
> snipped of Aahz saying that some disliked the *use* of lambda
> expressions (as opposed to the promotion of their result as superior).
> Stephen J. Turnbull wrote:
>> I think this is a difference of cognition.
> I do not think it a 'difference of cognition', in the usual sense of the
> term, to think that a more informative traceback is a teeny bit
> superior, and certainly not inferior, to a less informative traceback.
> Unless of course you mean that all disagreements are such.
The question is which traceback will be more informative. A 50-Meg
memory dump will be even more informative, but few people will want to
sift through it. I *think* at least some of the lambda lovers are
saying something akin to:
This little piece of logic isn't a worth naming as a section; it is
just something that I would do interactively once I got to this point.
I don't *want* a debugging pointer right to this line, I *want* to go
to the enclosing function to get my bearings.
I'm not convinced, because I've seen so many times when a lambda
actually is crucial to the bug. That said, I'm the sort of person who
will break up and name subunits even if I have to resort to names like
And I will certainly admit that there are times when it would be more
useful if the traceback showed the source code of the lambda instead
of showing <lambda> or skipping the frame.
More information about the Python-ideas