Tidy First? by Kent Beck

Tidy First? by Kent Beck

Author:Kent Beck
Language: eng
Format: epub, pdf
Publisher: O'Reilly Media
Published: 2023-10-17T00:00:00+00:00


After

You need to change behavior. The code is messy. You can’t see how to tidy. You change the behavior anyway (good for you—mess is no excuse). But now, huzzah!, you see how the change you made could have been easier. Do you tidy after?

It depends. Are you ever going to change the behavior in this same area again? (Likely yes, for reasons we’ll get into in the next section, but still apply your judgment.) If you’re going to change the area again, then a tidy after approach makes some sense.

Why not just tidy first the next time you need to change behavior in this area? It might be harder later. You may have forgotten context that makes tidying easier right now. Other changes may have interfered with the tidying you’d like to do now. If waiting to tidy at a later date substantially increases the cost of tidying, consider doing it now.

Also, how much tidying are we talking about? Say the behavior change took you an hour. Spending an hour tidying after makes sense. Spending a week tidying after? That doesn’t make sense. That goes on the Fun List.

So sure, tidy after, if:

You’re going to change the same area again. Soon.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.