I notice you said "args" not "arg". How would you parse foo(x, y -> x + y)? Even if the compiler can parse it, how about the human reading the code?<br><br>If lambda wasn't already there, I could see using (args) -> expr syntax but I think there shouldn't be two ways to do something so simple.<br>

<br>If you really want a shorter syntax, the obvious choice is foo(ëx, y: x + y).<br><br>--- Bruce<br><br><br><div class="gmail_quote">On Fri, Aug 7, 2009 at 5:49 PM, Greg Ewing <span dir="ltr"><<a href="mailto:greg.ewing@canterbury.ac.nz">greg.ewing@canterbury.ac.nz</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">My suggestion for a lightweight lambda syntax is<br>
<br>
  args -> expr<br>
<br>
Examples:<br>
<br>
  map(x -> x + 5, something)<br>
<br>
  d = defauldict(->[])<br>
<br>
-- <br><font color="#888888">
Greg</font><div><div></div><div class="h5"><br>
<br>
_______________________________________________<br>
Python-ideas mailing list<br>
<a href="mailto:Python-ideas@python.org" target="_blank">Python-ideas@python.org</a><br>
<a href="http://mail.python.org/mailman/listinfo/python-ideas" target="_blank">http://mail.python.org/mailman/listinfo/python-ideas</a><br>
</div></div></blockquote></div><br>