bloat-buster/tests/else_if_complicated.bbb
David Gonzalez Martin 4dedaf3006
All checks were successful
CI / ci (ReleaseFast, ubuntu-latest) (pull_request) Successful in 2m3s
CI / ci (ReleaseSmall, ubuntu-latest) (pull_request) Successful in 2m3s
CI / ci (ReleaseSafe, ubuntu-latest) (pull_request) Successful in 2m12s
CI / ci (Debug, ubuntu-latest) (pull_request) Successful in 3m13s
CI / ci (ReleaseFast, ubuntu-latest) (push) Successful in 2m3s
CI / ci (ReleaseSmall, ubuntu-latest) (push) Successful in 2m2s
CI / ci (ReleaseSafe, ubuntu-latest) (push) Successful in 2m7s
CI / ci (Debug, ubuntu-latest) (push) Successful in 3m10s
Else if and empty if
2025-04-17 16:50:06 -06:00

38 lines
621 B
Plaintext

Foo = enum
{
a,b,c,
}
[export] main = fn [cc(c)] (argument_count: u32) s32
{
>result: s32 = 0;
>foo: Foo = .b;
switch (foo)
{
.b =>
{
if (argument_count != 0)
{
>a: s32 = 1;
if (result == 1)
{
}
else if (result == 0)
{
return 0;
}
else
{
return 5;
}
return a;
}
},
else =>
{
}
}
return 0;
}