3 ms·
Luckily, all that stuff will be outdated with somewhat proper records https://github.com/ghc-proposals/ghc-proposals/pull/282 https://github.com/ghc-proposals/g
by k_bx 7y ago
Luckily, all that stuff will be outdated with somewhat proper records https://github.com/ghc-proposals/ghc-proposals/pull/282 https://github.com/ghc-proposals/ghc-proposals/pull/282
- nybble41 7y agoThe RecordDotSyntax extension is just syntactic sugar for the HasField typeclass. It doesn't make HasField "outdated". Anyway, the HasField typeclass (with the proposed change to support field updates[1]) does have at least one law: uncurry ($) (hasField @x r) == r or expressed with the getField and setField wrappers: setField @x r (getField @x r) == r [1] https://github.com/ghc-proposals/ghc-proposals/blob/master/proposals/0158-record-set-field.rst https://github.com/ghc-proposals/ghc-proposals/blob/master/p...