[Haskell-cafe] Tricky exception handling

Bulat Ziganshin bulatz at HotPOP.com
Tue Dec 13 04:28:32 EST 2005

Hello Joel,

Monday, December 12, 2005, 7:26:23 PM, you wrote:

JR> Unless I'm mistaken, the code above will run forever and will not
JR> exit on exception.

yes, you are muistaken! :)  this code will repeat permanently until
exception arrived. at this time it will process exception handler and
then exit the whole function. you musr reread docs. hmm, actually this
is the way exception handling works in ANY language

>> handle (...)
>>   repeat_forever
>>     do cmd <- read h ssl
>>        post $! Cmd $! cmd

JR> --
JR> http://wagerlabs.com/

Best regards,
 Bulat                            mailto:bulatz at HotPOP.com

More information about the Haskell-Cafe mailing list