PUBLIC
What I've found out is that this was because I was registering the ModDetails
as it comes out of tidyProgram. If instead I recreate the ModDetails form the
ModIface via initModDetails, the class op rules show up properly and everything
works as expected.
Is this documented some
PUBLIC
Hi,
I'm trying to compile the following two modules:
```
{-# LANGUAGE NoImplicitPrelude #-}
module MiniMonad where
class Functor f where
fmap :: (a -> b) -> f a -> f b
class (Functor f) => Applicative f where
pure :: a -> f a
class (Applicative m) => Monad m where
return ::
on it. And it provides a solid write up to refer to from the
implementation.
You could draw on this thread for the raw material, so it would not be hard to
write.
Simon
From: Christiaan Baaij
Sent: 07 March 2020 08:53
To: Simon Peyton Jones
Cc: Conal Elliott ; ghc-devs
Subject: Re: Class op
ojection" are implemented as rewrite rules
>> and executed the same way as other user-defined RULES
>> 2. These rules run first, and you cannot run anything before them
>>
>> Now my question is, is 1. actually true? or is that warning just a
>> (white) lie?
>
selector.
>
>
>
> I remember Conal raising this before, but I’ve forgotten the resolution.
> I’m entirely open to changes here, if someone is willing to do the work,
> including checking for consequences.
>
>
>
> Simon
>
>
>
> *From:* ghc-devs *On Behalf
y true? or is that warning just a (white)
> lie?
> If 1. is actually true, would there be any objections to adding a "-1"
> phase: where RULES specified to start from phase "-1" onward fire before
> any of the Class op rules.
> I'm quite willing to implement t
to changes here, if someone is willing to do the work, including
checking for consequences.
Simon
From: ghc-devs On Behalf Of Conal Elliott
Sent: 06 March 2020 17:37
To: Christiaan Baaij
Cc: ghc-devs
Subject: Re: Class op rules
Thank you for raising this issue, Christiaan! The current pol
> If 1. is actually true, would there be any objections to adding a "-1"
> phase: where RULES specified to start from phase "-1" onward fire before
> any of the Class op rules.
> I'm quite willing to implement the above if A) Class op rules are actually
> implemen
is that warning just a (white)
> lie?
> If 1. is actually true, would there be any objections to adding a "-1"
> phase: where RULES specified to start from phase "-1" onward fire before
> any of the Class op rules.
> I'm quite willing to implem
es run first, and you cannot run anything before them
Now my question is, is 1. actually true? or is that warning just a (white)
lie?
If 1. is actually true, would there be any objections to adding a "-1"
phase: where RULES specified to start from phase "-1" onward fire before
10 matches
Mail list logo