Ethan Furman added the comment:

Jesús Cea Avión added the comment:
> 
> If at your "top level" (module) you do:
> 
> """
> a = lambda x: 2*x
> """
> 
> You don't have an anonymous function, but a function called "a".

Actually, you do have an anonymous function, which happens to be bound to the 
name "a".

Compare:

    --> def a():
    ...     pass
    --> a.__name__
    'a'

and 

    --> a = lambda: None
    --> a.__name__
    '<lambda>'

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue19272>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to