4 ms·
Nice! That's something I like about Haskell and Elixir: the ability to define behavior for a given case. Though it looks like that's constrained to type-based d
by ubertaco 13y ago
Nice! That's something I like about Haskell and Elixir: the ability to define behavior for a given case. Though it looks like that's constrained to type-based dispatch (a la Java method overloading). Is there any way to define for specific values?
- hyperpape 13y agoIf I read this article properly, there's nothing yet standardized, but there's a possibility of future development: http://lukasz.langa.pl/8/single-dispatch-generic-functions/ http://lukasz.langa.pl/8/single-dispatch-generic-functions/.