Re: Parameterising Class Constraints in Existential Types

2001-03-30 Thread Johan Nordlander
Hi Ashley, Hugs currently restricts the way constrained existential types may be formed, for entirely internal, technical reasons. We're currently looking over the implementation to see if it's possible to lift the restriction without rewriting substantial parts of the type checker. -- Joha

RE: Parameterising Class Constraints in Existential Types

2001-03-29 Thread Simon Peyton-Jones
Parameterising Class Constraints in Existential Types | | | Is this valid (extended) Haskell? | | -- | class MyClass a b where | foo :: a -> b -> Int | | data Special = forall b. (MyClass Int b)=> MkSpecial b | data General a = forall b. (MyClass a b)=> MkGeneral b | -- | | Hugs compla

Parameterising Class Constraints in Existential Types

2001-03-29 Thread Ashley Yakeley
Is this valid (extended) Haskell? -- class MyClass a b where foo :: a -> b -> Int data Special = forall b. (MyClass Int b)=> MkSpecial b data General a = forall b. (MyClass a b)=> MkGeneral b -- Hugs complains about the 'General' line but has no problem with the 'Special' line... --