News for hackers. Stuff that matters.
Re:Absolute truths I unlearned as junior developer by JamesBarney on Friday June 07, 2019 @02:39PM (#20127450)
Comments rot, but so does everything else such as type names, tests, variable names, field names, designs, architectures, etc.
Re:Absolute truths I unlearned as junior developer by marvin on Friday June 07, 2019 @06:06PM (#20129038)
Yep - it doesn't help much with a method that's named EmptyCacheToPreventBlugblagCongestion() if external circumstances have stopped the blugblag from ever congesting any longer. So discipline in maintaining the intent of the code is required even if you never write a single comment.
Re:Absolute truths I unlearned as junior developer by lmm on Friday June 07, 2019 @10:09PM (#20130191)
Tests, types and field names get checked on build.
Re:Absolute truths I unlearned as junior developer by JamesBarney on Friday June 07, 2019 @11:05PM (#20130378)
If someone adds functionality to a type so the name isn't really applicable anymore I don't think the build catches that.
Re:Absolute truths I unlearned as junior developer by lmm on Saturday June 08, 2019 @05:12AM (#20131439)
As soon as you form something that should conform to the type (according to its name) and find that it doesn't, you notice the problem, and then you fix it once and for all (because the type is defined in one place). So yes, you can have misleading type names in the codebase, but there's a natural pressure to correct them, in a way that there largely isn't for misleading comments.