Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Disagree.

Reason: In Software Archeology (a.k.a. maintaining legacy code) you are often happy to get any kind of clue as to what went on inside someones head. Maybe they saw an edge case?

Of course you should write self-documenting code with variables and function names that explains most of it but when you either have to

1. factor out a new function

do_this_to_fix_that_weird_thing(weird state)

or

2. have to add a line

state == weird ? fix = fix+1:continue // weird is a weird state that sometimes occurs even though vendors api docs says otherwise.

please think twice.

Outdated comments are a problem but very often a problem I'll happily deal with compared to not having them at all. If a comment doesn't make sense you can also try checking VC history.



I will take 3

3. fix_bug_that_occurs_even_when_api_docs_say_otherwise(weird)




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: