[Haskell-beginners] Get things from IO monad
Felipe Almeida Lessa
felipe.lessa at gmail.com
Fri May 6 05:28:35 CEST 2011
On Fri, May 6, 2011 at 12:25 AM, aditya siram <aditya.siram at gmail.com> wrote:
> There is a function called "unsafePerformIO" which subverts this by
> turning an 'IO a' into an 'a', but it's not really meant for general
> use.
>
> This frustrated me in the beginning too, but I found that if I was
> using 'unsafePerformIO' too much the design was probably bad.
If you are a beginner, you should never use anything that starts with
'unsafe'. And you should *never* use 'unsafePerformIO'. And you
should *NEVER* use 'unsafeCoerce'.
Cheers, =)
--
Felipe.
More information about the Beginners
mailing list