Unexpected signal on hclosing stdout twice
Running 'hClose stdout' twice in a row causes Hugs to abort: Prelude> :l IO Reading file "/home/reid/local/lib/hugs/lib/IO.hs": Reading file "/home/reid/local/lib/hugs/lib/Ix.hs": Reading file "/home/reid/local/lib/hugs/lib/IO.hs": Hugs session for: /home/reid/local/lib/hugs/lib/Prelude.hs /home/reid/local/lib/hugs/lib/Ix.hs /home/reid/local/lib/hugs/lib/IO.hs IO> hPutStr stdout "abcde" >> hClose stdout abcde IO> hPutStr stdout "abcde" >> hClose stdout Unexpected signal -- Alastair Reid alastair@reid-consulting-uk.ltd.uk Reid Consulting (UK) Limited http://www.reid-consulting-uk.ltd.uk/alastair/
"Alastair Reid" <alastair@reid-consulting-uk.ltd.uk> writes:
Running 'hClose stdout' twice in a row causes Hugs to abort:
...
IO> hPutStr stdout "abcde" >> hClose stdout abcde IO> hPutStr stdout "abcde" >> hClose stdout
Unexpected signal
Thanks for the report - the repeated closing isn't the problem, but the handle you're trying to close. I've modified IO.hClose to treat closing of any of the standard handles as a nop. --sigbjorn
participants (2)
-
Alastair Reid -
Sigbjorn Finne