Sometimes I think Go was specifically made for Google to dictate its own preferences on the rest of us like some kind of power play. It enforces one single style of programming too much.
Also Go: exceptions aren't real, you declare and handle every error at every level or declare that you might return that error because go fuck yourself.
If this language feature is annoying to you, you are the problem. You 👏are 👏 the 👏 reason 👏 it 👏 exists.
I worked in places where the developers loaded their code full of unused variables and dead code. It costs a lot of time reasoning about it during pull request and it costs a lot of time arguing with coworkers who swear that they’re going to need that code in there next week (they never need that code).
This is a very attractive feature for a programming language in my opinion.
PS: I’m still denying your pull request if you try to comment the code instead.
❗️EDIT: A lot of y’all have never been to programming hell and it shows. 🪖 I’m telling you, I’ve fixed bayonets in the trenches of dynamically typed Python, I’ve braved the rice paddies of CICD YAML mines, I’ve queried alongside SQL Team Six; I’ve seen things in production, things you’ll probably never see… things you should never see. It’s easy to be against an opinionated compiler having such a feature, but when you watch a prod deployment blow up on a Friday afternoon without an easy option to rollback AND hours later you find the bug after you were stalled by dead code, it changes you. Then… then you start to appreciate opinionated features like this one. 🫡
I hate this in C++ when it does this with parameters of an overidden function. I don't need that specific parameter, but if I omit the variable name, I reduce readability.
The best part of these threads is no matter what someone comments, at least 2 people will reply either correcting or "clarifying" the original commenter.