c-cube / ocaml-trace

Common interface for tracing/instrumentation libraries in OCaml
https://c-cube.github.io/ocaml-trace/
22 stars 6 forks source link

b_queue: signal only if queue was empty #7

Closed tatchi closed 1 year ago

tatchi commented 1 year ago

I noticed that the example in the manual only signal other threads when the queue was empty (before we push). I'm not sure how it matters to avoid unnecessary Condition.sginal, but it seems sensible to me since we only wait when the queue is empty anyway.

c-cube commented 1 year ago

Thank you, that does make sense :-)