
23 Jul
2004
23 Jul
'04
12:24 p.m.
On 2004-07-23 at 19:18+0300 Kari Pahula wrote:
temp :: (Real a) => Object (Energy a) (HeatC a) -> Temp a temp Object (Energy e) (HeatC c) = Temp e*c
But this fails in hugs with: ERROR "temp.hs":22 - Constructor "Object" must have exactly 2 arguments in pattern
You've given temp three arguments: Object, (Energy e) and (HeatC c). You meant:
temp (Object (Energy e) (HeatC c)) = Temp e*c
HTH -- Jón Fairbairn Jon.Fairbairn@cl.cam.ac.uk