Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

FWIW. map() already exists. It's a global function, rather than being a protocol method, and it uses overloading. So you can still define functions merely by defining a new overload for map() that operates on your type.


Sigh, I typed "functors", not "functions", which should make a bit more sense. Autocorrect changed that without me noticing.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: