Mauricio <briqueabra...@yahoo.com> writes: > I'm trying, without success, to understand the difference > between existencial quantification and polymorphic > datatypes.
Polymorphic types are universally quantified; so id:: forall t. t -> t means that id works for every type t. If haskell had a symbol for existential quantification, hid:: exists t. t -> t would mean that hid only works on some type t, but it doesn't say what it is (so you could only ever apply hid to undefined. > Can you give me a hint Because being on the left of an arrow works something like negation, a type like (exists t. t -> t) -> bool can be written as forall t . (t -> t) -> bool -- Jón Fairbairn jon.fairba...@cl.cam.ac.uk http://www.chaos.org.uk/~jf/Stuff-I-dont-want.html (updated 2008-04-26) _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe