4 ms·
Yeah but I've also seen things like: AddsFiveToNum(num) { return num - 5 } A bunch too. So I don't think comments are solely at fault. Self documenting co
by ryanmcbride 4y ago
Yeah but I've also seen things like:
AddsFiveToNum(num) {
return num - 5
}
A bunch too. So I don't think comments are solely at fault. Self documenting code is only as good as the person who wrote it, and the people who approved it. Sometimes a comment is warranted, sometimes it's not.
- sgerenser 4y agoThat one drives me nuts. A while back I changed some code that had a bool called “uninit” that when true, meant the value was initialized.
- hoosieree 4y agoYesterday I learned that in emacs lisp, "defvar" is a definition that is set one time only and from that point on can never be changed (i.e. can not be VARied) and "defconst" is a definition that can be changed (i.e. is not CONSTant). Naming things is hard.