Skip to content

Comment on Zig is becoming more production-worthyparent

Comments

It does make prototyping more annoying but on the other hand it's nice, when reading code, to know that all variables have a reason to be there / aren't "non sequitur"s. It also catches bugs occasionally.

Making it an optional flag has the issue of making it easier to just say "just compile this always with --allow-unused-vars" instead of cleaning up the code. We kinda see that happening with warnings in C/C++.

That said, I too think we should investigate if there's a reasonable middle ground that could be found.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.