"James Stroud" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Because of my poorly designing a database, I have recently found it > necessary > to explore the wonders of the Python pseudo-switch: > > do_case = { "A" : lambda x: x["bob"], > "B" : lambda x: x["carol"], > "C" : lambda x: "Ted", > "D" : lambda x: do_something(x) } > > my_thing = do_case[get_value_from_thin_air()](adict) > > How to handle this kind of thing when lambda is removed from the > language, > beside the obvious def'ing those tiny little functions?
I don't believe any cast-in-concrete decision about lambda has been made yet. I expect there will be a PEP for removals when appropriate. Comments such as this will bolster the case against removal without replacement if then resubmitted TJR -- http://mail.python.org/mailman/listinfo/python-list