-
Notifications
You must be signed in to change notification settings - Fork 40
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
[WIP] microlens-pro #174
[WIP] microlens-pro #174
Conversation
Last commit is a nice starting point for discussion. Included are at least replacements for the faux Prisms and Isos from The main points of concern from the original thread included handling of This scheme of wrapping Another point of note is the obvious lack of documentation. microlens' documentation is leagues more approachable than lens', and thus should be handled with more care; i.e. not cut-and-pasted. a loose to-do list includes Template Haskell, and Haddocks. |
Thanks for opening! Looks like you have good progress already.
No objections, that sounds good to me. It sounds like the idea is that users would either import Lens.Micro / Lens.Micro.Platform or Lens.Micro.Pro depending on their situation. I think that's good. Re: the rest of the package: I'm less familiar with these lens features. Can you help explain your thought process for what definitions to include and not include? I see that most come from Control.Lens.Combinators but naturally not everything. From #105 I understand that we want prisms and isomorphisms but it looks like there are several related definitions as well. Basically, I'm wondering how we should choose whether to include a definition here or not? That will help me review this. |
In honesty, the decision on what definitions to keep was rather arbitrary. I went for at least what was included in In general, I'm not quite sure how to rule on a given definition's inclusion besides the vague notion of "microlens only needs the general combinators and a few optics for the types in |
That sounds good then! The PR looks good so far, feel free to send it out when you're ready. |
I think all that I'm confident doing is done. About updating the README:
|
Sounds good, I’ll take a look tonight.
I can measure these again for everything, it’s probably best to get more up to date numbers anyway.
I can do this separately, no need to wait for that. |
microlens-pro
Implements much of the essentials, along with some questionable features.
these are incomplete! i'd like the current haddocks to be more complete, and of course adding the missing docs
Lens.Micro.Pro.TH is cut-and-pasted from neongreen's stevenfontanella#107, with the small change s/PlainTV/plainTVInferred
de5b703
to
f438b03
Compare
I rebased on master and force-pushed. If you make any additional changes, please just back them up to a separate branch, force-pull (please be careful not to lose any work that wasn't pushed here) and then cherry-pick again before pushing here. I updated the CI to include microlens-pro, let's try to get it working before merging. I see failures now that I'll take a look at. |
overly-strict cabal version bounds might be behind the CI failures. They were generated with cabal gen-bounds under GHC 9.6.4 if I remember correctly |
Couldn't get working on ghc-7.10 :(. Main obstacle is |
I left some non-blocking comments. I'll merge and publish the v1 when the CI passes. Thanks a lot for this big contribution! |
I tried using the library a little bit. @crumbtoo, what do you think about changing Basically I don't see a reason to import |
That's true :p. I don't have any objections. |
Fixes #177. See #174 (comment) for rationale.
Fixes #177. See #174 (comment) for rationale.
Fixes #177. See #174 (comment) for rationale.
Draft PR to track progress on
microlens-pro
.Original issue: #105
Original WIP PR: #107 (which will serve as reference if not the base of this)
Are there any objections to following the path described in the original thread; that is, re-exporting
microlens-platform
with the imposter Prisms hidden and replaced with the lens-accurate definitions?