
18 Jul
2017
18 Jul
'17
2:29 p.m.
Hello list, I am writing a small console application. Today I was bitten by #2189 [1] ("hSetBuffering stdin NoBuffering doesn't work on Windows"). To reproduce: import System.IO main :: IO () main = hSetBuffering stdin NoBuffering >> getChar >>= putChar -- on linux you just need to press, say, 'c', on Win you -- need to press <Enter> too. Is there any sensible (cross-platform) way of working around this? [1] https://ghc.haskell.org/trac/ghc/ticket/2189