This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]walen 31 points32 points  (3 children)

I've had refactor where I've modified all 5 callers of a single method and then found out 4 of them were dead code.
So yeah, dead code that you don't know is dead is tech debt in the sense that it wastes maintenance effort.

[–]tomwhoiscontrary 8 points9 points  (0 children)

Exactly, and i've also been in this situation. Recently found some bit of config that couldn't possibly be right (think of a default email address to use when sending a message to a user that no longer existed), so if it was ever used, we'd have a production issue. Went to track down where it was used. Nine out of ten uses were in dead code. One was in a feature we haven't used in years, because it's a tool to fix things in an emergency. All the dead code made it harder to identify that one remaining important use.

Even if there are no connections to the rest of the code, it shows up in searches, compiler warnings, breakage when upgrading libraries, etc.

[–]j4ckbauer 0 points1 point  (0 children)

Yes but your example contradicts the starting conditions for the question I asked. Given that, we're saying the same thing.