From owner-freebsd-hackers Fri Aug 27 0:18:12 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from dt010nb9.san.rr.com (dt010nb9.san.rr.com [204.210.12.185]) by hub.freebsd.org (Postfix) with ESMTP id 15B1514CA6 for ; Fri, 27 Aug 1999 00:18:09 -0700 (PDT) (envelope-from Doug@gorean.org) Received: from localhost (doug@localhost) by dt010nb9.san.rr.com (8.9.3/8.8.8) with ESMTP id AAA67165; Fri, 27 Aug 1999 00:18:07 -0700 (PDT) (envelope-from Doug@gorean.org) Date: Fri, 27 Aug 1999 00:18:07 -0700 (PDT) From: Doug X-Sender: doug@dt010nb9.san.rr.com To: Chris Costello Cc: freebsd-hackers@FreeBSD.ORG Subject: Re: Please review: rc file changes In-Reply-To: <19990827015429.C18715@holly.calldei.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Fri, 27 Aug 1999, Chris Costello wrote: > On Thu, Aug 26, 1999, Doug wrote: > > > > 2. value ) instead of value) for case statements > > > > > > Why? What's wrong with `value)'? > > > > Nothing functionally, but I find case statements much easier to read with > > the extra whitespace. > > Would that not cause problems? Nope. As most things shell it (rightly) ignores the whitespace. Take a look at this little script to prove it to yourself: #!/bin/sh VAR=foo case $VAR in foo ) echo "I don't care about whitespace" ;; foo) echo "OOoops, guess I do" ;; esac VAR='foo ' case $VAR in foo ) echo "D'oh! I see the whitespace in the variable" ;; foo) echo "D'oh! I don't see the whitespace in the variable" ;; 'foo ' ) echo "I see what I am supposed to see" ;; esac Doug To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message