-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add getDown #68
Comments
Hm. At the moment, there is a list of things that getDown :: Down a -> a
getDown (Down x) = x But this is only a half-measure, since you wouldn't be able to use this backported form of |
I used it in code which looks like: src/Topograph.hs-transpose G {..} = G
src/Topograph.hs- { gVertices = map Down $ reverse gVertices
src/Topograph.hs: , gFromVertex = gFromVertex . getDown
src/Topograph.hs- , gToVertex = fmap Down . gToVertex I'd prefer it in d { getDown = 12 }
-- is the same as just
Down 12 i.e. it's not perfect shim, but better than no-shim. |
Also, https://downloads.haskell.org/~ghc/latest/docs/html/users_guide/glasgow_exts.html#record-pattern-synonyms if you really insist ;) but I'd be quite happy with just pseudo-selector function. (I wonder why it was added a selector functions, if there's some "measurable" benefit). |
True. As long as some part of |
Will do, not immediately though. |
Needs Data.Ord.Compat module
The text was updated successfully, but these errors were encountered: