logoalt Hacker News

acuozzoyesterday at 3:23 PM2 repliesview on HN

> For a lot of people, "fixing" means adding code to make it work.

What if the fix requires deleting a single line of code?

Is the additive fix to enshroud it in if (0) { } ?


Replies

Izkatayesterday at 8:58 PM

What I saw in these cases, the result was a few levels removed from the root cause and they'd add the same workaround to like 5 different places (and miss one or two) instead of tracking it back to the origin where the fix was that simple.

kqryesterday at 4:47 PM

Usually something more subtle like adding an early return somewhere before the offending line, or inheriting from that class and blanking that method, or something along those lines.