Path: utzoo!utgpu!watmath!clyde!att!osu-cis!tut.cis.ohio-state.edu!bloom-beacon!think!ames!pasteur!agate!saturn!ucscb.UCSC.EDU!funkstr From: funkstr@ucscb.UCSC.EDU (-=/ Larry Hastings /=-) Newsgroups: comp.lang.c Subject: Re: Standard indentation? Message-ID: <5651@saturn.ucsc.edu> Date: 7 Dec 88 09:05:37 GMT References:Sender: usenet@saturn.ucsc.edu Reply-To: funkstr@ucscb.UCSC.EDU (-=/ Larry Hastings /=-) Organization: MetaWare, Incorporated Lines: 31 +-In article , +-nelson@sun.soe.clarkson.edu (Russ Nelson) wrote +---------- | | I know, this is a religious question. However, I would like to know if | anyone has codified a standard for indentation of C programs? | +---------- Ain't no such animal; never will be. In fact, the UNIX program indent(1) has more options than ls(1). One thing I might suggest... if you're still deciding on whatever standard YOU are going to use, you could lean towards something you could define with indent options. THAT way, whenever you are looking at someone else's code, (someone else who, of COURSE, completely disagrees with your style of indenting, to the point of distraction) you can run it through indent so it will suddenly become READABLE. There is also cb(1), the original C pretty printer, which (I believe) formats your program to the indentation standard that K&R uses. cb is generally more available than indent. Also, cb won't change your code at all; indent is known to mess around with comments and sometimes declarations. -- /|\ /|\ .. . . . . . . . . . . | |\| |\| .. . . . . . . . . . . |/|\|/|\|/|| _ _ _ _ |_| _ _ |_ -__ _ _ARPA: funkstr@ucscb.ucsc.EDU | |/| |/|L_ (_\( ( (_/ | |(_\_) (_ || )(_)_)UUCP: *!ucbvax!ucscb!funkstr \|/ \|/ larry / hastings _/ WORK: sun!acad!metaware!funkster MetaWare Incorporated Disclaimer: It was a bad day. "If any of your OSF force are caught or killed, the Secretary will deny any knowlege of your activities." --from the new Mission: Impractical