"running": PROTECTED wakeup;
authorwenzelm
Wed Aug 01 16:48:47 2007 +0200 (2007-08-01)
changeset 2410824e5587603b4
parent 24107 fecafd71e758
child 24109 952efb77cf91
"running": PROTECTED wakeup;
"cont": actually invoke wakeup!!
src/Pure/ML-Systems/multithreading_polyml.ML
     1.1 --- a/src/Pure/ML-Systems/multithreading_polyml.ML	Tue Jul 31 23:23:34 2007 +0200
     1.2 +++ b/src/Pure/ML-Systems/multithreading_polyml.ML	Wed Aug 01 16:48:47 2007 +0200
     1.3 @@ -137,10 +137,9 @@
     1.4            | Exn.Exn exn =>
     1.5                (PROTECTED "status" (fn () => status := exn :: ! status); continue cont))
     1.6        | (Task.Finished, _) =>
     1.7 -         (PROTECTED "running" (fn () => (dec active; dec running));
     1.8 -          wakeup_all ()))
     1.9 +         (PROTECTED "running" (fn () => (dec active; dec running; wakeup_all ()))))
    1.10      and continue cont =
    1.11 -      (PROTECTED "cont" (fn () => queue := cont (! queue)); wakeup_all; work ());
    1.12 +      (PROTECTED "cont" (fn () => queue := cont (! queue); wakeup_all ()); work ());
    1.13  
    1.14      (*main control: fork and wait*)
    1.15      fun fork 0 = ()