the standard way to do that is use an existential wrapper:
(This needs -fglasgow-exts or some flags)
module Main where
class Interface x where
withName :: x - String
data A = A String
instance Interface A where
withName (A string) = Interface A with ++ string ++
data B = B
ChrisK [EMAIL PROTECTED] wrote:
the standard way to do that is use an existential wrapper:
Does this relate to the basket of fruit problem in object
oriented languages?
You created the existential wrapper to allow a multimorphic
list type?
--
_jsn
Jason Dusek wrote:
ChrisK [EMAIL PROTECTED] wrote:
the standard way to do that is use an existential wrapper:
Does this relate to the basket of fruit problem in object
oriented languages?
You created the existential wrapper to allow a multimorphic
list type?
When you access the