You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
today I played around with Djinn a bit, and noticed what I am pretty sure is a bug:
I added a definition for an Arrow typeclass, and the Kleisli wrapper for a Monad.
Then, I tried to derive an instance Arrow (Kleisli m).
Input:
Djinn> class Arrow arr where id :: arr a a; (.) :: arr b c -> arr a b -> arr a c; toArr :: (b -> c) -> arr b c; first :: arr b c -> arr (b, d) (c, d)
Djinn> data Kleisli m a b = MkKleisli (a -> m b)
Djinn> ?instance Arrow (Kleisli m)
Expected result: an instance Arrow (Kleisli m) or a message that this is not possible.
Actual result: an error:
Djinn> ?instance Arrow (Kleisli m)
instance Arrow (Kleisli m) where
djinn: IntMap.!: key 3 is not an element of the map
CallStack (from HasCallStack):
error, called at libraries/containers/Data/IntMap/Internal.hs:569:17 in containers-0.5.10.2:Data.IntMap.Internal
I'll try to shrink the example, but so far this is all I have.
Best regards,
David Kofler
The text was updated successfully, but these errors were encountered:
On Wed, Jun 6, 2018 at 09:18 David Kofler ***@***.***> wrote:
Hello,
today I played around with Djinn a bit, and noticed what I am pretty sure
is a bug:
I added a definition for an Arrow typeclass, and the Kleisli wrapper for
a Monad.
Then, I tried to derive an instance Arrow (Kleisli m).
Input:
Djinn> class Arrow arr where id :: arr a a; (.) :: arr b c -> arr a b ->
arr a c; toArr :: (b -> c) -> arr b c; first :: arr b c -> arr (b, d) (c, d)
Djinn> data Kleisli m a b = MkKleisli (a -> m b)
Djinn> ?instance Arrow (Kleisli m)
Expected result: an instance Arrow (Kleisli m) or a message that this is
not possible.
Actual result: an error:
Djinn> ?instance Arrow (Kleisli m)
instance Arrow (Kleisli m) where
djinn: IntMap.!: key 3 is not an element of the map
CallStack (from HasCallStack):
error, called at libraries/containers/Data/IntMap/Internal.hs:569:17 in
containers-0.5.10.2:Data.IntMap.Internal
I'll try to shrink the example, but so far this is all I have.
Best regards,
David Kofler
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#6>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFAInrJtfYG-yALZ66tpA4luCZ7BN3Q5ks5t6ADJgaJpZM4Uc9VO>
.
Hello,
today I played around with Djinn a bit, and noticed what I am pretty sure is a bug:
I added a definition for an
Arrow
typeclass, and theKleisli
wrapper for a Monad.Then, I tried to derive an instance
Arrow (Kleisli m)
.Input:
Expected result: an instance
Arrow (Kleisli m)
or a message that this is not possible.Actual result: an error:
I'll try to shrink the example, but so far this is all I have.
Best regards,
David Kofler
The text was updated successfully, but these errors were encountered: