From owner-cvs-all Fri Jul 20 4:50:17 2001 Delivered-To: cvs-all@freebsd.org Received: from whale.sunbay.crimea.ua (whale.sunbay.crimea.ua [212.110.138.65]) by hub.freebsd.org (Postfix) with ESMTP id 8D53437B403; Fri, 20 Jul 2001 04:50:00 -0700 (PDT) (envelope-from ru@whale.sunbay.crimea.ua) Received: (from ru@localhost) by whale.sunbay.crimea.ua (8.11.2/8.11.2) id f6KBmdc81924; Fri, 20 Jul 2001 14:48:39 +0300 (EEST) (envelope-from ru) Date: Fri, 20 Jul 2001 14:48:39 +0300 From: Ruslan Ermilov To: Bruce Evans Cc: Bruce Evans , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/share/man/man9 style.9 Message-ID: <20010720144839.F65677@sunbay.com> Mail-Followup-To: Bruce Evans , Bruce Evans , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org References: <20010720113310.C30828@sunbay.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from bde@zeta.org.au on Fri, Jul 20, 2001 at 09:35:41PM +1000 Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Fri, Jul 20, 2001 at 09:35:41PM +1000, Bruce Evans wrote: [...] > I think, strictly speaking, `if' after `else' begins a new clause so it needs > a first-level indent: > > if (...) { > ... > } else { > if (...) { > ... > } else { > if (...) { > ... > } > } > } > > but `else if' is idiomatic -- no one writes an else-if ladder like the above. > Anyway, the continuation indent rule is at the lexical level, so it doesn't > apply to `else if'. > Doh, and why I have removed that final `else' part? :-) What I was talking about was: if (mylevel == SLC_DEFAULT) { slctab[(int)func].current.flag = flag; slctab[(int)func].current.val = val; flag |= SLC_ACK; } else if (hislevel == SLC_CANTCHANGE && mylevel == SLC_CANTCHANGE) { flag &= ~SLC_LEVELBITS; flag |= SLC_NOSUPPORT; slctab[(int)func].current.flag = flag; } else { ... } Should that be written as shown? Thanks, -- Ruslan Ermilov Oracle Developer/DBA, ru@sunbay.com Sunbay Software AG, ru@FreeBSD.org FreeBSD committer, +380.652.512.251 Simferopol, Ukraine http://www.FreeBSD.org The Power To Serve http://www.oracle.com Enabling The Information Age To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message