View Single Post
  #15   Spotlight this post!  
Unread 29-04-2004, 15:09
Dave Flowerday Dave Flowerday is offline
Software Engineer
VRC #0111 (Wildstang)
Team Role: Engineer
 
Join Date: Feb 2002
Rookie Year: 1995
Location: North Barrington, IL
Posts: 1,366
Dave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond reputeDave Flowerday has a reputation beyond repute
Re: Coding / Style Standards for sharing C code

Quote:
Originally Posted by Joe Johnson
Okay, Mark is one. How about some more folks? Dave Flowerday? Kevin Watson?
I'm willing to help out too, although I agree with Mark that it will be difficult to convince teams to follow a coding standard which isn't one that they created. I know here at work our coding standard gives a reasoning for each stipulation like where the braces go and such, and for most of them the reason is just basically "We had to pick one, and this is the one we picked. Deal with it." Instead of asking teams to follow a coding standard, maybe just enforce the standard on code in the repository? Teams wouldn't have to follow the standard (unless they wanted to add code to the repository), yet anything they pull from the repository would still follow a consistent standard. Perhaps, just like most software companies, code should be reviewed by a group of peers before it's accepted into the repository? That would make it easy to at ensure that the code in the repository followed some standard and also give users of the code some level of confidence that the code is decent and relatively bug-free. It would potentially discourage some contributors, but maybe that's better than having a repository that is just flooded with code, some useful, some incomprehensible, some that works, and some that doesn't?

Also, I've mentioned it before I think, but there's a wonderful little tool available for Unix/Linux and Cygwin that could be useful here - it's called "Artistic Style" and it will reformat code to a certain standard - it lets you specify tabs versus spaces, indent levels, whether to attach braces or put them on the next line, etc. I use it at work quite a bit to easily bring outside code at least that much closer to the rest of ours.