Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re: The One True Style of indentation:

by mattr (Curate)
on Apr 15, 2002 at 10:40 UTC ( #159130=note: print w/ replies, xml ) Need Help??


in reply to The One True Style of indentation:

I use two spaces for manual indentation in Perl, and to continue a block of information in my own todo lists which are ascii, two newlines separating each block. It prints well and looks sane to me..

I use XEmacs which seems to get it right, tab eq 2 spaces. Personally I just find it to be the right amount, it generally leaves me enough room for short comments on the same line even when nested.

I learned curlies from Niklaus & Wurth but forget what they said.. I use

if (true) {
  woop;
} else {
  werp;
}

..Vertical real estate is important too. The real holy war is, how do you line up long || statements (over 2 lines for me)..

if ( (longthing > foo) || (anotherthing < moo) || (boo) ) { werp; }
Right??!?!?!? (smiling like jack n. in the shining) hee hee hah hah ahaha ahaa!!


Comment on Re: The One True Style of indentation:
Download Code
Re: Re: The One True Style of indentation:
by tretin (Friar) on Apr 15, 2002 at 12:43 UTC
    TAB's what it's all about. Easy to keep anything and everything lined up perfectly, and with a minimum of counting and such...

    work it harder make it better do it faster makes us stronger more than ever hour after our work is never over.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://159130]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (8)
As of 2014-08-30 19:33 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (293 votes), past polls