Re: [Haskell] Partially applied type class functions

2005-08-06 Thread Paul Govereau
Thanks alot for the clarifications. If I understand correctly, I ran into the monomorphism restriction because of the constraint on the type variable. The Haskell report says this in Section 4.5.5: In addition, the constrained type variables of a restricted declaration group may not be gener

[Haskell] Re: Partially applied type class functions

2005-08-06 Thread Andre Pang
On 07/08/2005, at 12:47 AM, Srinivas Nedunuri wrote: Finally a plain English explanation of the silly thing. Thank you! I tried reading the Haskell report's version of it, and yes I'm sure it has all the gory technical details, but at the end I was still left thinking So exactly what is the

[Haskell] Re: Partially applied type class functions

2005-08-06 Thread Srinivas Nedunuri
Finally a plain English explanation of the silly thing. Thank you! I tried reading the Haskell report's version of it, and yes I'm sure it has all the gory technical details, but at the end I was still left thinking So exactly what is the monomorphism restriction? Why on earth couldn't they have ad

[Haskell] unsafePerformIO and optimizations

2005-08-06 Thread Wolfgang Jeltsch
Hello, http://haskell.org/ghc/docs/latest/html/libraries/base/ System.IO.Unsafe.html#v%3AunsafePerformIO talks about what optimizations you should disable if you apply unsafePerformIO to an action which contains side effects. These are: * inlining of functions which call unsafePerf