>>>>> "Cale" == Cale Gibbard <[EMAIL PROTECTED]> writes:

    Cale> So, the first version:

    Cale> import System.IO import Control.Exception (try)

    Cale> main = do mfh <- try (openFile "myFile" ReadMode) case mfh
    Cale> of Left err -> do putStr "Error opening file for reading: "
    Cale> print err Right fh -> do mline <- try (hGetLine fh) case
    Cale> mline of Left err -> do putStr "Error reading line: " print
    Cale> err hClose fh Right line -> putStrLn ("Read: " ++ line)

Left? Right?

Hardly descriptive terms. Sounds like a sinister language to me.
-- 
Colin Adams
Preston Lancashire
_______________________________________________
Haskell-Cafe mailing list
Haskell-Cafe@haskell.org
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to