test_comptime_invalid_cast.zig (163B) - Raw
1 comptime { 2 const value: i32 = -1; 3 const unsigned: u32 = @intCast(value); 4 _ = unsigned; 5 } 6 7 // test_error=type 'u32' cannot represent integer value '-1'
zigfork of https://codeberg.org/ziglang/zig | |
| Log | Files | Refs | README | LICENSE |