aboutsummaryrefslogtreecommitdiff
path: root/test/cases/compile_errors/ptrFromInt_with_misaligned_address.zig
blob: cc008ea9ee410f103277f6dc02f6de8903f04908 (plain)
1
2
3
4
5
6
7
8
9
10
pub export fn entry() void {
    var y: [*]align(4) u8 = @ptrFromInt(5);
    _ = &y;
}

// error
// backend=stage2
// target=native
//
// :2:41: error: pointer type '[*]align(4) u8' requires aligned address