Re: Perl Style

2004-02-01 Thread Robert
Jeff 'Japhy' Pinyan wrote: On Jan 31, Robert said: When they say "uncuddled else" are they meaning: A cuddled else is: if (...) { ... } else { ... } Anything other than THAT is an uncuddled else. Got it. Thanks! -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional comman

Re: Perl Style

2004-01-31 Thread Jeff 'japhy' Pinyan
On Jan 31, Robert said: >When they say "uncuddled else" are they meaning: A cuddled else is: if (...) { ... } else { ... } Anything other than THAT is an uncuddled else. -- Jeff "japhy" Pinyan [EMAIL PROTECTED] http://www.pobox.com/~japhy/ RPI Acacia brother #734 htt

RE: Perl Style

2004-01-31 Thread Tim Johnson
I would guess either that or if() { #code } else { #more code } which I have seen, usually by people who primarily code in C. -Original Message- From: Robert [mailto:[EMAIL PROTECTED] Sent: Sat 1/31/2004 2:24 PM To: [EMAIL PROTECTED]

Re: Perl Style?

2001-08-27 Thread Peter Scott
At 08:27 AM 8/27/01 -0600, Rob Waggoner wrote: >If this is not an appropriate place to wax philosophic about perl, let me >know and I will take my questions else where. I think it's fine. You might get a little more informed response from comp.lang.perl.moderated. >I'm curious to hear from ot

RE: Perl Style?

2001-08-27 Thread Rogers, Gary (AP- Server Adminstrator)
Personally I'd have to say... it depends.. If it's a short and dirty script that will eventually be thrown away and never modified by anyone other than yourself, it can be as messy as it has to be to get the job done. If on the other hand there's ever a possiblility that it will be used by someo

Re: Perl Style Question

2001-06-26 Thread Jeff Yoak
At 06:05 PM 6/26/01 -0400, Gross, Stephan wrote: >Why is this style > >if ($x) { > do this; > do that; >} > >typically preferred over > >if ($x) >{ >do this; >do that; >} > This tends to be a hotly debated religious issue. There are people who use that later abomination. ;-) T

Re: Perl Style Question

2001-06-26 Thread Brett W. McCoy
On Tue, 26 Jun 2001, Gross, Stephan wrote: > Why is this style > > if ($x) { > do this; > do that; > } > > typically preferred over > > if ($x) > { >do this; >do that; > } > > I like the latter example because it's easier to cut and paste the braces > and everything in between. I

Re: Perl Style Question

2001-06-26 Thread Paul
--- iain truskett <[EMAIL PROTECTED]> wrote: > I use cuddled if what I'm doing would look silly otherwise. e.g. > > if ($blah) { > one line; > } elsif ($flurp) { > one line; > } else { > one line; > } Hey! I think that was the thing that made me switch! =o) In C I could say if

Re: Perl Style Question

2001-06-26 Thread iain truskett
* Paul ([EMAIL PROTECTED]) [27 Jun 2001 00:50]: > --- iain truskett <[EMAIL PROTECTED]> wrote: > > * Gross, Stephan ([EMAIL PROTECTED]) [26 Jun 2001 22:16]: [...] > I always used the second in C, but once I started using Perl and Java > I kept finding something happening that made it seem more con

Re: Perl Style Question

2001-06-26 Thread Paul
--- iain truskett <[EMAIL PROTECTED]> wrote: > * Gross, Stephan ([EMAIL PROTECTED]) [26 Jun 2001 22:16]: > > Why is this style > > > if ($x) { > > do this; > > do that; > > } > > > typically preferred over > > > if ($x) > > { > >do this; > >do that; > > } I always used the sec

Re: Perl Style Question

2001-06-26 Thread Peter Scott
At 06:05 PM 6/26/01 -0400, Gross, Stephan wrote: >Why is this style > >if ($x) { > do this; > do that; >} > >typically preferred over > >if ($x) >{ >do this; >do that; >} > >I like the latter example because it's easier to cut and paste the braces >and everything in between. I als

Re: Perl Style Question

2001-06-26 Thread Adam Turoff
On Tue, Jun 26, 2001 at 06:05:15PM -0400, Gross, Stephan wrote: > Why is this style > > if ($x) { > do this; > do that; > } This style is also known as The One True Brace Style, popularized by Kernighan & Ritchie (in _The C Programming Language_). It's also popular with other languages

Re: Perl Style Question

2001-06-26 Thread iain truskett
* Gross, Stephan ([EMAIL PROTECTED]) [26 Jun 2001 22:16]: > Why is this style > if ($x) { > do this; > do that; > } > typically preferred over > if ($x) > { >do this; >do that; > } > I like the latter example because it's easier to cut and paste the > braces and everything in b

Re: Perl Style Question

2001-06-26 Thread Paul Johnson
On Tue, Jun 26, 2001 at 06:05:15PM -0400, Gross, Stephan wrote: > Why is this style > > if ($x) { > do this; > do that; > } > > typically preferred over > > if ($x) > { >do this; >do that; > } > > I like the latter example because it's easier to cut and paste the braces > a