Hacker News new | ask | show | jobs
by himom 2918 days ago
Swift closure syntax, at least in <= 2.0, made for awkward API calls, since it wasn’t clear whether inline or after closures were used.

In Ruby,

    a.map(&:succ)
1 comments

If you have a named function, rust lets you do

    a.map(succ)
as well, since functions can be used where closures can, as long as the types work.
Same in JS