Meg's Mirrors
zig
about
heads
tags
log
tree
search
Search
zig
test
cases
compile_errors
while_expected_optional_got_bool.zig
pretty
plain
permalink
blame
history
•
12 lines
•
172 B
1
export fn foo() void {
2
while (bar()) |x| {
3
_ = x;
4
}
5
}
6
fn bar() bool {
7
return true;
8
}
9
10
// error
11
//
12
// :2:15: error: expected optional type, found 'bool'