Marc Loxton
Posts: 9
Nickname: spoonchops
Registered: Feb, 2006
|
|
Re: How Important is Coding Style, and How Do You Enforce It?
|
Posted: Feb 6, 2007 7:22 PM
|
|
> I'm familiar with Emerson's quote, but I think the keyword > here is "foolish". Consistency, in itself, is not a bad > thing, and can be very useful, such as not having to learn > to drive a car, any time you're going to drive a new car, > and can instead focus on more interesting things.
Consistency across a codebase isn't a bad thing at all, in fact it's a good thing. However consistency over time without the constant reassessment of your position on the matter as you learn new things is a foolish consistency indeed. The rest of this quote goes on to talk about just that.
To equate this to your car example manufacturers have a consistent way to change gears in a car with a manual transmission. The gear stick is in between the two front seats and you move it through a H pattern to select gears, this is consistent across most (a few cars have the steering wheel mounted paddle shift or steering column mounted stick shift) modern cars. It is NOT the same as changing gears in a model T ford or some other early cars which had levers between legs and all sorts of things. Each car company being consistent over time in this case would have been somewhat foolish.
|
|