More anti-region sentiments.

Around this time last year while I was working with Kent Skinner at thePlatform and were ripping out the #REGION sections wherever we found them in legacy code, we Googled for the phrase “Regions are Evil” and didn’t find any matches.

Now I’m delighted to say that in addition to my rant from a few months ago, I’ve recently found a few other anti-region arguments. including the specific “Regions are Evil” phrase we predicted.

Mind you, in the comments of one blog, someone calls the anti-region sentiment “a load of elitist horsecrap”. I think I can live with that, though. I’ve been called worse.

Links:

http://blog.jayfields.com/2005/05/do-youregion.html

http://www.oobaloo.co.uk/articles/2007/6/6/visual-studio-regions-are-evil

One thought on “More anti-region sentiments.

  1. You know who I am says:

    Regions work “well” in one instance: when you have your hands tied inside someone else’s code that’s badly designed, most specifically not properly encapsulated. Especially when the resulting class is multiple thousands of lines long and you’ve got to have some approximation of organization to comprehend what the class is trying to do.

    Yes, the ideal solution would be to fix the code, but you’re not always “allowed” in some business environments (“too much time” or “belongs to someone else”, there are so many excuses). A region tag might, at that point, be the one cushion between you, the unwilling consumer of this code, and the bullet you want to put through your own head to end the misery.

    So, yes, regions are bad: regions are a poor coping skill for bad code. But sometimes in old-fashioned command-and-control organizations it’s all you’ve got — if you don’t have the balls and momentum to force a corporate-wide coding-values ethos change. I guess instead I should have been bringing Kool-Aid to those Friday morning donut fests.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: