On 8/3/07, Isaac Dupree <[EMAIL PROTECTED]> wrote:
> The surprise is that an unconstrained type-variable being variable
> rather than instantiated to an arbitrary type, makes any difference
> (since it doesn't, normally, at runtime).

Right... it's surprising because types aren't supposed to "matter" at runtime.

> I would guess the programs
> `Bool` and `a` are the same once optimizations are turned on?  Maybe GHC
> could avoid the creation of type-lambdas that are unused (in some
> sense)... with -Onot... I'm dubious about that.
>

Right, both programs result in the same runtime behavior if
optimizations are turned on. (Which, of course, is another surprising
thing: the program with the type signature omitted loops if compiled
with -Onot and terminates if compiled with -O.)

Cheers,
Tim

-- 
Tim Chevalier * [EMAIL PROTECTED] * Often in error, never in doubt
_______________________________________________
Glasgow-haskell-users mailing list
Glasgow-haskell-users@haskell.org
http://www.haskell.org/mailman/listinfo/glasgow-haskell-users

Reply via email to