[Haskell-cafe] How to understand the 'forall' ?

David Menendez dave at zednenem.com
Wed Sep 16 05:11:25 EDT 2009


On Wed, Sep 16, 2009 at 4:18 AM, Bulat Ziganshin
<bulat.ziganshin at gmail.com> wrote:
> Hello Cristiano,
>
> 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.

That would be forall a. a -> Int.

The only value of type (forall a. a) is _|_.

-- 
Dave Menendez <dave at zednenem.com>
<http://www.eyrie.org/~zednenem/>


More information about the Haskell-Cafe mailing list