I have (roughly) the following code:
data Foo e
type MFoo e = Maybe (Foo e)
instance Ord e = Monoid (Foo e) where
f1 `mappend` f2 = code invoking the mappend instance from Maybe (Foo e)
I'd expect this to optimize to the same thing as if I had implemented:
meld :: Ord e = Foo e - Foo e - Foo e
wasserman.louis:
I have (roughly) the following code:
data Foo e
type MFoo e = Maybe (Foo e)
instance Ord e = Monoid (Foo e) where
f1 `mappend` f2 = code invoking the mappend instance from Maybe (Foo e)
I'd expect this to optimize to the same thing as if I had implemented:
meld :: Ord