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

There are nicer ways to do structural typing.

Here's just one example:

I have a post here of how you can partially define structure to be filled in by the consumer of the API: http://bitemyapp.com/posts/2014-04-11-aeson-and-user-created...

Can't do this without polymorphism and higher-kinded types.



I'm using this approach for a library that is currently in development. It works very well.




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

Search: