Meg's Mirrors
zig
about
heads
tags
log
tree
search
Search
zig
test
cases
compile_errors
int_to_err_global_invalid_number.zig
pretty
plain
permalink
blame
history
•
13 lines
•
189 B
1
const Set1 = error{
2
A,
3
B,
4
};
5
comptime {
6
var x: u16 = 3;
7
var y = @errorFromInt(x);
8
_ = .{ &x, &y };
9
}
10
11
// error
12
//
13
// :7:27: error: integer value '3' represents no error