bloat-buster/tests/bool_pair.bbb
David Gonzalez Martin eb88c61f88
All checks were successful
CI / ci (MinSizeRel, ubuntu-latest) (push) Successful in 34s
CI / ci (Release, ubuntu-latest) (push) Successful in 31s
CI / ci (RelWithDebInfo, ubuntu-latest) (push) Successful in 36s
CI / ci (Debug, ubuntu-latest) (push) Successful in 2m46s
Compile first executable with self-hosted compiler
2025-06-04 21:25:30 -06:00

19 lines
242 B
Plaintext

BoolPair = struct
{
a: u1,
b: u1,
}
bool_pair = fn () BoolPair
{
return { .a = 0, .b = 1 };
}
[export] main = fn [cc(c)] () s32
{
>result = bool_pair();
if (result.a) #trap();
if (!result.b) #trap();
return 0;
}