[Haskell-cafe] Faster timeout but is it correct?

Job Vranish job.vranish at gmail.com
Mon Feb 21 22:11:53 CET 2011


I'm curious, is it possible that your new timeout implementation would fix
this problem?:

doesntWork :: Int -> Int
doesntWork x = last $ cycle [x]

test :: IO (Maybe Bool)
test = timeout 1 $ evaluate $ doesntWork 5 == 5 -- never terminates, even
with the timeout



More information about the Haskell-Cafe mailing list