cvs commit: hugs98/lib Prelude.hs hugs98/lib/exts ConcBase.hs

reid 2001/04/03 12:29:27 PDT Modified files: lib Prelude.hs lib/exts ConcBase.hs Log: When a thread blocks on an MVar, we have to take the complete state of the thread and store it in the MVar. This used to be easy because the state was all in the success continuation but exception handlers live on the stack so we have to unwind the stack making a list of all the exception handlers and store that list of exception handlers into the MVar too. This is done by returning a Hugs_BlockThread object. When catch sees one of these, it adds a Hugs_Catch into the object and returns Hugs_BlockThread again. Eventually, this gets up to the top thread loop which, finally, does the write into the MVar. Trivial changes: o Improved error messages if a forked thread ends in error or exception o Replaced the word "process" with "thread" in comments. "process" implies some measure of isolation (namespace, heap, file descriptors, etc.) whereas "thread" just impliues a separate thread of control. These are _not_ processes! [Hey, I work on operating systems these days - they're fussy about these definitions.] Revision Changes Path 1.8 +8 -3 hugs98/lib/Prelude.hs 1.4 +10 -10 hugs98/lib/exts/ConcBase.hs
participants (1)
-
Alastair Reid