[Haskell-cafe] How to understand the 'forall' ?
bulat.ziganshin at gmail.com
Wed Sep 16 04:18:34 EDT 2009
Wednesday, September 16, 2009, 12:04:48 PM, you wrote:
> Yep, perhaps I used the wrong example. What about foo: (forall a. a) -> Int?
it's a function that convert anything to integer. for example:
foo _ = 1
it's hard to find better examples, since haskell has very few
functions with fully polymorphic arguments
Bulat mailto:Bulat.Ziganshin at gmail.com
More information about the Haskell-Cafe