Merge pull request #3675 from Vexu/atomic-store
Add @atomicStore builtin
This commit is contained in:
@@ -2,6 +2,16 @@ const tests = @import("tests.zig");
|
||||
const builtin = @import("builtin");
|
||||
|
||||
pub fn addCases(cases: *tests.CompileErrorContext) void {
|
||||
cases.add(
|
||||
"atomic orderings of atomicStore Acquire or AcqRel",
|
||||
\\export fn entry() void {
|
||||
\\ var x: u32 = 0;
|
||||
\\ @atomicStore(u32, &x, 1, .Acquire);
|
||||
\\}
|
||||
,
|
||||
"tmp.zig:3:30: error: @atomicStore atomic ordering must not be Acquire or AcqRel",
|
||||
);
|
||||
|
||||
cases.add(
|
||||
"missing const in slice with nested array type",
|
||||
\\const Geo3DTex2D = struct { vertices: [][2]f32 };
|
||||
|
||||
Reference in New Issue
Block a user