News for hackers. Stuff that matters.
Re:My poor use of golang's defer woke me up by seanmcdirmid on Sunday June 22, 2014 @10:00PM (#7929838)
You can always take the experience, but often the old code exists in such a misguided architecture that it is better to scrap it vs. unwind multitudes of bad uninformed decisions (b.c. you know better now!).

Re-writing code is actually almost always harder than writing it from scratch, but we do it for other benefits: interoperability with legacy components, legacy of expected behavior (warts and all), risk (the old code is debugged), and culture (programs in the team know that code). But if you don't have those requirements, you will often come out behind in rewriting all code rather than going with a green field.

It also depends on whether the work one is doing is cutting edge (lots of experimentation and learning required) or basic dev work over relatively well known concepts.

Re:My poor use of golang's defer woke me up by pdkl95 on Monday June 23, 2014 @02:55AM (#7930582)
As Brooks said, "Plan to throw one away; you will, anyhow."

There is value in a prototype - even if you don't actually use any piece of the prototype in the final product.

Re:My poor use of golang's defer woke me up by dagw on Monday June 23, 2014 @03:02AM (#7930597)
If you're going to quote Brooks, it might be worth noting that he's had a slight change of heart on that point: http://www.wired.com/2010/07/ff_fred_brooks/