Peter Hercek wrote: > When 'exists' is not a keyword, why 'forall' is needed at all? > Isn't everything 'forall' qualified by default?
“forall” isn't a keyword in Haskell 98. As an extension to the language, however, it makes certain types expressible that can not be written in H98, for example f :: (forall a. a) -> T which is different from g :: forall a. a -> T although both are not particularly useful. (The only argument that f will ever take is bottom!) In the context of existentially quantified types, however, the forall keyword is used probably to make the use of an extension more explicit. Without the forall keyword, data U = C a would be an existential, while the programmer maybe really wanted the usual data U a = C a Kalman ---------------------------------------------------------------------- Find out how you can get spam free email. http://www.bluebottle.com/tag/3 _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe