Yes sorry….but this still fails with….
“`numberType1' is a rigid type
variable bound by”
From:
Brent Yorgey [mailto:byorgey@gmail.com]
Sent: 21 December 2007 17:29
To: Nicholls, Mark
Cc: Jules Bean;
haskell-cafe@haskell.org
Subject: Re: [Haskell-cafe] nice
simple problem for someone struggling....
"class ShapeInterface shape where
area :: shape->Int"now looks dubious....I want it to be something like
"class ShapeInterface shape where
area :: Num numberType => shape->Int" ?
Rather, I think you probably want
class ShapeInterface shape where
area :: Num numberType => shape -> numberType
-Brent