One Line Times Two
Oct. 20th, 2022 10:09 pm![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
I fixed two bugs today by removing one line of code for each bug.
(Ok, I made another small change for one of the bugs, but it was cleaning up something else on the call stack that could have caused a problem under some circumstances. I think *that* change was three lines.)
One of my friends at work notes that if you take fewer lines of code to do something, you reduce the opportunities for introducing bugs. If I can manage to delete down to zero lines of code, there will be no bugs left at all.
Wait! There's something wrong with that...
(Ok, I made another small change for one of the bugs, but it was cleaning up something else on the call stack that could have caused a problem under some circumstances. I think *that* change was three lines.)
One of my friends at work notes that if you take fewer lines of code to do something, you reduce the opportunities for introducing bugs. If I can manage to delete down to zero lines of code, there will be no bugs left at all.
Wait! There's something wrong with that...