diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2019-02-09 18:57:39 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-02-09 18:57:39 -0500 |
| commit | 1864acd32608ae917f8afc11b11f08a4bb362cef (patch) | |
| tree | d96b50a927fc67583d88c71822513594609621fb /std/atomic/stack.zig | |
| parent | 48c1e235cb620dacc30254d0898390b4d97f3e73 (diff) | |
| parent | ca8580ece1ab07215b72394cc4ab3030bf9df139 (diff) | |
| download | zig-1864acd32608ae917f8afc11b11f08a4bb362cef.tar.gz zig-1864acd32608ae917f8afc11b11f08a4bb362cef.zip | |
Merge remote-tracking branch 'origin/master' into llvm8
Diffstat (limited to 'std/atomic/stack.zig')
| -rw-r--r-- | std/atomic/stack.zig | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/std/atomic/stack.zig b/std/atomic/stack.zig index 503fa0c0ce..4d0d5075e0 100644 --- a/std/atomic/stack.zig +++ b/std/atomic/stack.zig @@ -1,6 +1,7 @@ const assert = std.debug.assert; const builtin = @import("builtin"); const AtomicOrder = builtin.AtomicOrder; +const expect = std.testing.expect; /// Many reader, many writer, non-allocating, thread-safe /// Uses a spinlock to protect push() and pop() @@ -108,14 +109,14 @@ test "std.atomic.stack" { { var i: usize = 0; while (i < put_thread_count) : (i += 1) { - std.debug.assertOrPanic(startPuts(&context) == 0); + expect(startPuts(&context) == 0); } } context.puts_done = 1; { var i: usize = 0; while (i < put_thread_count) : (i += 1) { - std.debug.assertOrPanic(startGets(&context) == 0); + expect(startGets(&context) == 0); } } } else { |
