News for hackers. Stuff that matters.
Re:A Proposal for Package Versioning in Go by nvarsj on Tuesday March 27, 2018 @06:03PM (#16693169)
I really like Go overall, especially for systems work. But there's various quirks that hurt my day to day productivity, and I think they only exist due to stubbornness.

For example, why do unused variables and imports, a style issue, cause a compiler error? This is a constant pain if commenting out lines of code during debugging or prototyping. On the other hand, the compiler doesn't care if I ignore or forget to check error values - which is almost always incorrect behavior.

Re:A Proposal for Package Versioning in Go by agnivade on Wednesday March 28, 2018 @02:32PM (#16700423)
> For example, why do unused variables and imports, a style issue, cause a compiler error?

Here's why - https://golang.org/doc/faq#unused_variables_and_imports

Re:A Proposal for Package Versioning in Go by shabbyrobe on Tuesday March 27, 2018 @07:30PM (#16693773)
Yeah for sure, it's definitely got its warts. I suspect the import thing was far easier to code as an error than to compute whether they need to be pruned. Gotta love those go build times though! With vim-go and goimports, it's handled automatically for me on save so I don't find that an issue any more. Unused variables, on the other hand...