get the name of lambda
George Yoshida
ml at dynkin.com
Sat Oct 16 08:48:04 EDT 2004
More information about the Python-list mailing list
Sat Oct 16 08:48:04 EDT 2004
- Previous message (by thread): get the name of lambda
- Next message (by thread): get the name of lambda
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Just out of curiosity, is there any way to get the name of a lambda expression? Lambdas are anonymous functions, so it's a stupid idea to get the name of it. But if it's possible, how could I? Let's take a simple example: foo = lambda:None foo.__name__(or foo.func_name) returns '<lambda>'. I'm looking for a way to return 'foo', instead of '<lambda>'. Thanks in advance. -- George
- Previous message (by thread): get the name of lambda
- Next message (by thread): get the name of lambda
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list