3 ms·
That blog post seems fairly outdated. There are several lenses libraries that provide decent record support: http://stackoverflow.com/questions/5767129/lenses-
by nandemo 14y ago
That blog post seems fairly outdated. There are several lenses libraries that provide decent record support:
http://stackoverflow.com/questions/5767129/lenses-fclabels-data-accessor-which-library-for-structure-access-and-mutatio http://stackoverflow.com/questions/5767129/lenses-fclabels-d...
Personally, I'd much rather have a better baked-in record system, but that's unlikely to change substantially now.
- applicative 14y agoThe state of the art is the amazing `lens` package https://github.com/ekmett/lens/wiki/Overview https://github.com/ekmett/lens/wiki/Overview . See this example, https://github.com/ekmett/lens/blob/master/examples/Pong.hs https://github.com/ekmett/lens/blob/master/examples/Pong.hs
- Qerub 14y agoLooks great! I hope it gets more broadly adopted. Thanks for sharing.
- Qerub 14y agoThe post might be old, but AFAIK there have been no significant changes in the built-in record system since. Sure, there are great lens libraries but until the Haskell community blesses one of them the result is a mess of many incompatible record systems. Not exactly the best way to foster a thriving open source community.