zig/test/behavior/bugs/13064.zig
Andrew Kelley 48798da29b Merge pull request #13074 from topolarity/stage2-opt
stage2: Miscellaneous fixes to vector arithmetic and copy elision
2023-01-09 13:59:04 -07:00

18 lines
466 B
Zig

const std = @import("std");
const builtin = @import("builtin");
const expect = std.testing.expect;
test {
if (builtin.zig_backend == .stage2_arm) return error.SkipZigTest; // TODO
if (builtin.zig_backend == .stage2_aarch64) return error.SkipZigTest; // TODO
if (builtin.zig_backend == .stage2_c) return error.SkipZigTest; // TODO
var x: [10][10]u32 = undefined;
x[0][1] = 0;
const a = x[0];
x[0][1] = 15;
try expect(a[1] == 0);
}