Anonymus functions revisited
bruno modulix
onurb at xiludom.gro
Tue Mar 22 11:07:36 EST 2005
More information about the Python-list mailing list
Tue Mar 22 11:07:36 EST 2005
- Previous message (by thread): Anonymus functions revisited
- Next message (by thread): Anonymus functions revisited
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Diez B. Roggisch wrote: >>letting tuples-like objects (x,y,z=0) acting as functions on other >>tuples I wonder why this would not be a good starting point of >>rethinking anonymus functions? >> >>In Georges proposition the action is >> >> (x,y,z=0) -> (x,y,z) >> >>i.e. mapping tuples on other tuples. This is equivalent to >> >>lambda x,y,z=0:(x,y,z) > > > As you say for yourself, that's just lambda in disguise. Not exactly in fact - unless I messed something. There are 2 problems here: a more flexible tuple unpacking, *and* a lambda in disguise. Actually, I'd go + 1 for the first, -1 for the second > So I guess the same > arguments about the in- or exclusion of lambda apply here. For the second part, yes. Not for the first one. > I personally > like lambda, but _can_ live without it. Yes, one can live without... <troll> ...and without list comprehensions, __call__ and other special methods, descriptors, metaclasses, first class functions, builtin datatypes like lists and dicts, exceptions, dynamic typing, garbage collection, etc too. Hurray, let's all happily program in assembly !-) </troll> -- bruno desthuilliers ruby -e "print 'onurb at xiludom.gro'.split('@').collect{|p| p.split('.').collect{|w| w.reverse}.join('.')}.join('@')"
- Previous message (by thread): Anonymus functions revisited
- Next message (by thread): Anonymus functions revisited
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list