To my request on Haskell-2
...
class (Ring r,AddGroup (m r)) = RightModule m r
where
cMul :: m r - r - m r
-- "vector" (m r) multiplied by "coefficient" r'
...
instance Ring r = RightModule r r where cMul = mul
Haskell rejects this `= RightModule r
I cannot find there the subject. Could you citate?
Sorry, it turns out I missed your point entirely.
class (Ring r,AddGroup (m r)) = RightModule m r where
cMul :: m r - r - m r
So here, m :: *-*
What you really want is to say
instance Ring r = RightModule (\t-t) r where