News for hackers. Stuff that matters.
Re:Parse, Don’t Validate by runeks on Friday November 08, 2019 @04:11AM (#21480866)
DerivingVia is a generalization of GeneralizedNewtypeDeriving. The former can do everything the latter can and more. https://downloads.haskell.org/~ghc/latest/docs/html/users_gu...
Re:Parse, Don’t Validate by Quekid5 on Friday November 08, 2019 @06:11PM (#21487893)
Exactly. I intentionally avoid GND because it can be quite wonky, and DerivingVia basically subsumes it. You do still have to have slightly more explicit declarations of instances, but IMO it's worth it for the control.