RE: Eager IO function

2002-02-13 Thread Simon Marlow
> > How should I modify the function below so that characters > are printed > > out as they arrive? > > > > printchar :: Handle -> IO () > > printchar handle = do c <- hGetChar handle > > putChar c > > Try using > hSetBuffering handle NoBuffering > hSetBufferi

Re: Eager IO function

2002-02-13 Thread Malcolm Wallace
> How should I modify the function below so that characters are printed > out as they arrive? > > printchar :: Handle -> IO () > printchar handle = do c <- hGetChar handle > putChar c Try using hSetBuffering handle NoBuffering hSetBuffering stdout NoBuffering fr