News for hackers. Stuff that matters.
Re:-2000 Lines of Code by hinkley on Saturday March 23, 2024 @08:32AM (#39799466)
It was five to six lines of code repeated in half a dozen spots in a dozen files, with different variable names, and different arguments. And I wasn’t deleting them, I was replacing them with the same function call.
Re:-2000 Lines of Code by aidos on Saturday March 23, 2024 @09:24AM (#39799760)
That’s got “macro” written all over it.
Re:-2000 Lines of Code by jraph on Saturday March 23, 2024 @09:43AM (#39799880)
That's a sed /d of course. Or a "Replace all in folder" in any decent code editor.

Or a sufficiently efficient "extract to method" on a decent IDE, that notices the different occurrences even with renamed variables.

Unless those lines of code were subtly edited all over the place and needed careful and subtly different replace for each occurrence, or at last review because that's what's truly evil with duplicated code. It's forks that diverged to maintain N times in your codebase.