Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: Indent Perl

by Mago (Parson)
on Jan 22, 2005 at 07:03 UTC ( [id://424201]=note: print w/replies, xml ) Need Help??


in reply to Indent Perl


* 4-column indent.
* Opening curly on same line as keyword, if possible, otherwise line up.
* Space before the opening curly of a multi-line BLOCK.
* One-line BLOCK may be put on one line, including curlies.
* No space before the semicolon.
* Semicolon omitted in "short" one-line BLOCK.
* Space around most operators.
* Space around a "complex" subscript (inside brackets).
* Blank lines between chunks that do different things.
* Uncuddled elses.
* No space between function name and its opening parenthesis.
* Space after each comma.
* Long lines broken after an operator (except "and" and "or").
* Space after last parenthesis matching on current line.
* Line up corresponding items vertically.
* Omit redundant punctuation as long as clarity doesn't suffer.


Mago
mago@rio.pm.org


Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-04-20 02:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found