+1 -- This is another good code layout option.

-----Original Message-----
From: Per Mellqvist [mailto:[EMAIL PROTECTED]]
Sent: Thu, December 13, 2001 8:44 AM
To: '[EMAIL PROTECTED]'
Subject: [Eap-features] Code Style - parenthesize boolean expressions


I'd like an option in the Code Style settings to 
insert parentheses in boolean expressions when not present.
Preferably with some added options for when to use spaces
(not in the innermost subexpr).

The point of course would be to make the code easier to read,
and not have to try to remember all precedence rules to figure
out what goes on.

A simple example

if (a != null && !b.equals("") || c != 0) {
}

would become (I hope:)

if ( ( (a != null) && (!b.equals("")) ) ||
     (c != 0) ) {
}

// Per Mellqvist

-------------------------------------------------- 
DISCLAIMER 
This e-mail, and any attachments thereto, is intended only for use by the
addressee(s) named herein and may contain legally privileged and/or
confidential information.  If you are not the intended recipient of this
e-mail, you are hereby notified that any dissemination, distribution or
copying of this e-mail, and any attachments thereto, is strictly prohibited.
If you have received this e-mail in error, please immediately notify me and
permanently delete the original and any copy of any e-mail and any printout
thereof. 

E-mail transmission cannot be guaranteed to be secure or error-free.  The
sender therefore does not accept liability for any errors or omissions in
the contents of this message which arise as a result of e-mail transmission.

NOTICE REGARDING PRIVACY AND CONFIDENTIALITY 

Knight Trading Group may, at its discretion, monitor and review the content
of all e-mail communications. 


_______________________________________________
Eap-features mailing list
[EMAIL PROTECTED]
http://www.intellij.com/mailman/listinfo/eap-features

Reply via email to