-
Notifications
You must be signed in to change notification settings - Fork 65
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
mtl 3.0 planning #116
Comments
|
Also, does it make sense to crack |
With regard to a proper |
add an update monad a la https://danel.ahman.ee/papers/types13postproc.pdf ? |
@gbaz I've considered this, but this would require a monoid action type class, which we'd also end up having to 'own'. |
Ooo dibs |
@emilypi If we decide to go this way, we definitely need to consider the fundep question. I personally favour 'action determines state'. It does mean we basically can't provide almost any instances, though. |
Uh. I have feelings about this. I've made several attempts and bounced off of the question of which which is approach is best for several reasons. On one hand, I hate biting the overlapping/overlappable/incoherent approach of using raw MPTC (i.e. The solution, if we were to go down the overlapping road, would be to backpack a la @ekmett's Deltas in On the other hand, Regardless, we also run into the problem into the problem of committing this to |
I strongly oppose any kind of typechecker soup arising from not having fundeps on a multi-param type class. The biggest pain for me is that the most natural such fundep (action determines state) means that certain 'obvious' instances become literally un-writeable. Consider more-or-less the canonical implementation of the functionality of I definitely don't know how I feel about such a cost: it essentially pushes all instances onto users. However, I'd rather that than the alternatives, which is typechecker slurry or significant complexity. I don't know in how far Backpack would help this, but this means becoming immediately incompatible with Stack, for example. While I don't really care much for Stack, and consider it useless in 2022, I don't think many people will agree with me, especially on a package as 'core' as |
Also, could we add 'laws and tests for these'? I'm already laying the groundwork, but it'd be nice to have that too. |
One thing I have wanted a few times is a Unfortunately I don't actually know how feasible / sensible this factoring would be in practice. |
From chats with Ed, which would also affect
|
Per discussions with @ekmett and elsewhere
MonadReader
intoAsk
andLocal
classesMonadWriter
intoTell
andListen
, andPass
FunctorTell
,ApplicativeAsk
)catch
(see: https://paste.tomsmeding.com/aAYwOy7t)Thoughts welcome
The text was updated successfully, but these errors were encountered: