From: sof Date: Sun, 18 May 1997 04:19:21 +0000 (+0000) Subject: [project @ 1997-05-18 04:19:21 by sof] X-Git-Tag: Approximately_1000_patches_recorded~673 X-Git-Url: http://git.megacz.com/?a=commitdiff_plain;h=ec8dac9d4d011593623c99380858ceedd36f5139;p=ghc-hetmet.git [project @ 1997-05-18 04:19:21 by sof] getLine defined in terms of hGetLine --- diff --git a/ghc/lib/ghc/PrelIO.lhs b/ghc/lib/ghc/PrelIO.lhs index 0d99d24..24bf95b 100644 --- a/ghc/lib/ghc/PrelIO.lhs +++ b/ghc/lib/ghc/PrelIO.lhs @@ -43,10 +43,7 @@ getChar :: IO Char getChar = hGetChar stdin getLine :: IO String -getLine = do c <- getChar - if c == '\n' then return "" else - do s <- getLine - return (c:s) +getLine = hGetLine stdin getContents :: IO String getContents = hGetContents stdin