Skip to content
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

Fix strictness semantics of State and Writer #194

Merged
merged 5 commits into from
Jul 31, 2019

Conversation

KingoftheHomeless
Copy link
Collaborator

@KingoftheHomeless KingoftheHomeless commented Jul 28, 2019

This closes #192 and closes #193

@@ -24,6 +24,7 @@ module Polysemy.Internal.Combinators

import qualified Control.Monad.Trans.State.Lazy as LS
import qualified Control.Monad.Trans.State.Strict as S
import qualified Data.Tuple as S (swap)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The swap defined in this module was my attemp to get around runFixpoint diverging. I don't think it's necessary anymore.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's not, since the fixpoint tests I added still succeed. Still, maybe we want the lazy swap for runLazyState?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants