Info about ongoing work on Clean
Nick Kallen
phantom@earthlink.net
Mon, 22 Dec 1997 15:17:42 -0800
>>>Extending Clean with
>>>- multi-parameter type constructor classes
>
>Take a look at:
> http://www.cse.ogi.edu/~erik/Personal/multi.htm
I read this article. (Sounds like a good extension!). I wanted to point out
this extract to the list (it relates to a previous discussion):
(p. 3):
One could imagine overloading Haskell's field selectors by declaring a class
class Hasf a b where
f :: a -> b
for any field label f. So if we have the data type Foo = Foo {foo :: Int},
we would get a class declaration
class Hasfoo a b
where foo :: a -> b
and an instance declaration
instance Hasfoo Foo Int
where foo (Foo foo) = foo
This is just a cut-down version of the kind of extensible records that were
proposed by Jones (Jones [1994]).