From 555a69a0de4845ae2c3e36d96c7fe06bc175f77a Mon Sep 17 00:00:00 2001 From: Simon Cruanes Date: Fri, 16 Sep 2022 17:00:51 -0400 Subject: [PATCH] test: in emit1, use implicit local storage --- tests/bin/emit1.ml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/tests/bin/emit1.ml b/tests/bin/emit1.ml index d5196413..faaeca12 100644 --- a/tests/bin/emit1.ml +++ b/tests/bin/emit1.ml @@ -23,16 +23,17 @@ let run_job () = let@ () = Fun.protect ~finally:(fun () -> Atomic.set stop true) in let i = ref 0 in while not @@ Atomic.get stop do - let@ scope = + let@ _scope = Atomic.incr num_tr; T.Trace.with_ ~kind:T.Span.Span_kind_producer "loop.outer" ~attrs:[ "i", `Int !i ] in for j = 0 to 4 do + (* parent scope is found via thread local storage *) let@ scope = Atomic.incr num_tr; - T.Trace.with_ ~kind:T.Span.Span_kind_internal ~scope + T.Trace.with_ ~kind:T.Span.Span_kind_internal ~attrs:[ "j", `Int j ] "loop.inner" in