[Haskell-cafe] Array bug?

Svein Ove Aas svein.ove at aas.no
Mon Nov 3 14:56:17 EST 2008


On Mon, Nov 3, 2008 at 4:55 PM, Henning Thielemann
>
> I think it is a good idea to switch this feature on and off by a compiler
> switch. It does not alter the correctness of a program. If the program is
> incorrect, the switch does only affect the way how the program goes wrong.
>

I disagree.
In a normal program, you may want to mix the two - use the safe
functions for untrusted input, the unsafe ones once you have already
validated the input.

Such a switch, if it existed, should only affect the *unsafe* version
of the call - this way, it would be possible to remove all chance of
corruption from a program at need.

Also, of course, the exceptions should be catchable based on the new
ghc 6.10 exception library (on ghc 6.10, anyhow)


More information about the Haskell-Cafe mailing list