[Haskell-cafe] Why purely in haskell?

David Roundy daveroundy at gmail.com
Wed Jan 9 17:15:18 EST 2008

On Jan 9, 2008 4:21 PM, Don Stewart <dons at galois.com> wrote:
> anton:
> > OTOH, the freedom to change things on the fly can be nice to have, and
> > if used with "great responsibility" (mainly an understanding of what's
> > safe to do and what isn't), the downside can be vanishingly small.
> It can be small, unless you need to have any kind of static assurance
> (say for high assurance software, or for new kinds of optimisations, or
> if you want to reorder code in the compiler for parallelism).
> Then the downside to arbitrary, untracked effects in the system is huge.

I just want to point out that unsafePerformIO is at the core of the
(safe) bytestring library.  As SPJ et al pointed out, this is crucial
functionality, and is only unsafe if unsafely used.  (Yes, it's
unsafe, but you can write a safe module with a purely safe interface
that uses unsafePerformIO in its core.)


More information about the Haskell-Cafe mailing list