clarified messages streaming (again, amending 5ea3ed3c52b3): avoid too many small messages stacking up, e.g. when loading HOL-Analysis.Analysis.thy into Isabelle/jEdit;
authorwenzelm
Wed Dec 04 19:40:22 2019 +0100 (2 days ago)
changeset 71231dafa5fce70f1
parent 71229 be2c2bfa54a0
child 71232 7b9ff966974f
clarified messages streaming (again, amending 5ea3ed3c52b3): avoid too many small messages stacking up, e.g. when loading HOL-Analysis.Analysis.thy into Isabelle/jEdit;
src/Pure/Concurrent/consumer_thread.scala
     1.1 --- a/src/Pure/Concurrent/consumer_thread.scala	Wed Dec 04 15:36:58 2019 +0100
     1.2 +++ b/src/Pure/Concurrent/consumer_thread.scala	Wed Dec 04 19:40:22 2019 +0100
     1.3 @@ -104,11 +104,7 @@
     1.4            }
     1.5          }
     1.6  
     1.7 -        if (continue) {
     1.8 -          val msgs1 = msgs.drop(reqs.length)
     1.9 -          val msgs2 = mailbox.receive(timeout = Some(Time.zero))
    1.10 -          main_loop(msgs1 ::: msgs2)
    1.11 -        }
    1.12 +        if (continue) main_loop(msgs.drop(reqs.length))
    1.13          else robust_finish()
    1.14      }
    1.15