A long time ago (early 90's) I was invited to do a piece for Ed Yordon's rag, American Programmer. The issue was about code reuse. Just to be contrary, I wrote about "The Case for Starting Over" and went into the software ageing process. The overall design and implementation can handle some kinds of changes, but not others.
in reply to Reusing code is good; reinvention might be better
So there are objective criteria you can use to decide if a module/project/function should be rewritten or modified.