You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Error: local variable is not used, but in fact it is #832
The transpiler emits "error: local variable is not used", but in fact it is used.
Compiling
main: () = {
b := true;
i := 0;
while i < 3 && b next i++ {
std::cout << i << std::endl;
}
}
yields
whiles.cpp2(2,3): error: local variable b is not used; consider changing its name to '_' to make it explicitly anonymous, or removing it entirely if its side effects are not needed
Activity
gregmarr commentedon Nov 15, 2023
This check was added in 243d03d
Emit anonymous functions as `constexpr` or `mutable` lambdas