News for hackers. Stuff that matters.
Re:Generics can make your Go code slower by dcgudeman on Wednesday March 30, 2022 @02:04PM (#30858667)
Hmm yes, why stop there? Why have functions? Just reimplement business logic all over your codebase. That way each block of code has everything you need to know. Sure, functions have been adopted by every other language/ecosystem and are universally known to be useful despite a few downsides but you could say the same about package management and that hasn't deterred you yet.
Re:Generics can make your Go code slower by dahfizz on Wednesday March 30, 2022 @02:19PM (#30858836)
You're arguing against a straw man. I could just as easily say "why not make every line of code it's own function?"

C has libraries, and my comment made it clear that they are useful.

Argue against my actual point:

By not having a bespoke package manager, and instead relying on the system package manager, you end up with higher quality dependencies and with dramatically less bloat in C than other language ecosystems. It is all the benefit and none of the drawbacks of npm-like ecosystems.

Re:Generics can make your Go code slower by dcgudeman on Wednesday March 30, 2022 @02:47PM (#30859243)
I don't agree with your assessment that libraries in C are higher quality. Additionally I have yet to see a system package manager that enables developers to install dependencies at a specific version solely for a project without a lot of headaches. All the venv stuff in python is necessary python dependencies are installed system wide. The idea that the C/C++ ecosystem is better off because it doesn't have its own package manager is a bizarre idea at best.
Re:Generics can make your Go code slower by imtringued on Thursday March 31, 2022 @05:10AM (#30865247)
I'm one of the few humans on the planet that installs his dependencies inside the project folder and uses PYTHONPATH.