juan albornoz <[EMAIL PROTECTED]> writes: > Hello I need to catch some exceptions which I've "thrown" with the > error function. I am using WinHugs 98. Can any one help me?
Something along the lines of: import qualified Exception as E foo = E.catch <mumble> (\e -> print e) should do you. See the papers on exception handling: http://www.reid-consulting-uk.ltd.uk/alastair/publications/except-pldi.ps.gz and the documentation for the library http://www.haskell.org/ghc/docs/latest/html/base/Control.Exception.html (This is GHC documentation but the Hugs library is mostly compatible. The main differences are in things not covered by the original paper - see the (quite readable) source code for the Hugs version of Exception for details.) -- Alastair Reid [EMAIL PROTECTED] Reid Consulting (UK) Limited http://www.reid-consulting-uk.ltd.uk/alastair/ _______________________________________________ Haskell mailing list [EMAIL PROTECTED] http://www.haskell.org/mailman/listinfo/haskell