From owner-freebsd-questions@FreeBSD.ORG Tue Jun 8 01:00:21 2004 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E167816A4CE for ; Tue, 8 Jun 2004 01:00:21 +0000 (GMT) Received: from smtp.owt.com (smtp.owt.com [204.118.6.19]) by mx1.FreeBSD.org (Postfix) with ESMTP id 91ACB43D41 for ; Tue, 8 Jun 2004 01:00:21 +0000 (GMT) (envelope-from kstewart@owt.com) Received: from [207.41.94.233] (owt-207-41-94-233.owt.com [207.41.94.233]) by smtp.owt.com (8.12.8/8.12.8) with ESMTP id i580xPbI012661; Mon, 7 Jun 2004 17:59:25 -0700 From: Kent Stewart To: freebsd-questions@freebsd.org, dgw@liwest.at Date: Mon, 7 Jun 2004 18:00:15 -0700 User-Agent: KMail/1.6.2 References: <200406072155.10022.dgw@liwest.at> In-Reply-To: <200406072155.10022.dgw@liwest.at> MIME-Version: 1.0 Content-Disposition: inline Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Message-Id: <200406071800.15137.kstewart@owt.com> cc: "Goodleaf, John" Subject: Re: OT: group coding standards X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Jun 2004 01:00:22 -0000 On Monday 07 June 2004 02:55 pm, Daniela wrote: > On Monday 07 June 2004 20:10, Goodleaf, John wrote: > > Hello, > > I'm abusing the mailing list because many of you are sickeningly > > clever and have long experience in IT. I'm working to establish > > a document (yep) providing guidance for our company's > > small-but-growing IT group with regard to coding standards and > > practices. It seems rife with potential problems and there is > > already the potential for one of those variable-naming holy wars > > (e.g. intVariableName, varname, VarName, varName). So my > > question: is there a good document out there on the net somewhere, > > maybe hiding at a University site from which I can draw for general > > consideration? Any experiences? Recommendations? > > > > It's a hard problem. How do you provide conventions that don't > > annoy the hell out of programmers, but which ensure that legibile, > > maintainable code is left? > > Well, other programmers may have a different opinion, but I can at > least tell you what I would prefer: > I would have no problems with coding standards that allow you to > clean up _after_ a session, because I lose half of my good ideas > while bothering with coding standards. Good would be some convention > where you can just modify your code with sed(1) afterwards, that's > not much overhead. > I used to think this was really true and then I started working in a group that dealt with computer controlled manufacturing. One of the people was a whiz at generating code. My mental image of him generating code has him running between rows of plants that produced a lot of polen dust as he ran. The amount of code he produced was amazing just like the clouds of polen dust. The problem was that he would make off_by_1 errors that would take as much as a year to track down. Programming fast doesn't mean much if some one has to come behind you and fix what you didn't do right. If you don't think like them, it is almost impossible if it wasn't documented as it was written. In my situation, since the program was now my responsibility, I was the one they called at 2am when one of the loader porgrams died because of one of the off_by_1 errors. There has to be a happy median. I just never figured out where that was before I retired :). Kent -- Kent Stewart Richland, WA http://users.owt.com/kstewart/index.html