3 ms·
On the other hand, it’s also pretty bad to have a code base with a few iterations of “copy function; edit lightly; leave now stale comments untouched; replace s
by karatinversion 5y ago
On the other hand, it’s also pretty bad to have a code base with a few iterations of “copy function; edit lightly; leave now stale comments untouched; replace some, possibly all, calls to old function with new ; do not delete old function ever.”
- gonzo41 5y agoctrl + alt + h on most ide's will list the callers of a function. It's pretty safe to repeat things and delete things, version control is a safety net. I've done a lot of legacy work, and most repetition is due to a loss of business context. Naturally support staff don't want to be hero's and make big changes. Right now I work with a system that's been in active development for 30 years and it's a dream to work on because everyone knows it and I can just ask some of the original authors what something is, or to explain an edge case. Most dev's aren't that lucky.
- y4mi 5y ago> ctrl + alt + h on most ide's will list the callers of a function that very much depends of how the function is called. there are a lot of ways I've encountered in the wild which wouldn't be found by this.