4 ms·
Cant remember where I read this, but I realized a while back the folly of "rewriting your code". Your code looks messy because it works. Its the result of weeks
by jeffjose 14y ago
Cant remember where I read this, but I realized a while back the folly of "rewriting your code". Your code looks messy because it works. Its the result of weeks of testing and bug fixes. It can handle special cases and is robust.
Many a times, to start of, a clever 5 or 10 lines would suffice. But the moment you start testing it for production, it'd require more and more logic to handle _all_ the cases.
- TimJRobinson 14y agoI think this is very common with new simple magical frameworks / languages too. They work really well for most common tasks but can't handle the edge cases.
- samnardoni 14y agoI'm pretty sure you're referring to a Joel Spolsky article, "Things you should never do". http://www.joelonsoftware.com/articles/fog0000000069.html http://www.joelonsoftware.com/articles/fog0000000069.html
- jawr 14y agoExcellent post, thanks for the link.
- deleted 14y ago[deleted]
- Lewton 14y agoDon't rewrite, refactor!