Hacker News new | ask | show | jobs
by gf000 552 days ago
The solution is easy, have separate debug and release modes and only mandate variables to be used in the latter (though still provide a flag to disable the check, for the occasional debugging an issue that only happens with the release config).

Alsl, automatic `_ = var` is the worst of all, now instead of the compiler showing me one-by-one the few variables I'm not using temporarily so I can fix those, I instead have made n modifications all across the codebase (remember, this is all recursive) that are syntactically correct and won't be shown by the compiler.

1 comments

Zig already has a seperate debug mode, if you feel the issue is important, file an issue on the zig GitHub page
Given that this is quite a controversial topic, I don't think they would allow such issues, besides the currently existing ones.