Skip to content

Commit

Permalink
tests: fix concurrency test
Browse files Browse the repository at this point in the history
  • Loading branch information
mertcandav committed Dec 3, 2024
1 parent 9789d83 commit 24dc68c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/concurrency/main.jule
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ use "std/sync/atomic"
static mut n = atomic::Int.New(0)

fn addToN(mut wg: &sync::WaitGroup) {
n.Add(1, atomic::MemoryOrder.Relaxed)
n.Add(1, atomic::SeqCst)
wg.Done()
}

Expand All @@ -23,5 +23,5 @@ fn main() {

wg.Wait()

println(n.Load(atomic::MemoryOrder.Relaxed))
println(n.Load(atomic::SeqCst))
}

0 comments on commit 24dc68c

Please sign in to comment.