RFR (XS): 8037043: put Method flag bits in predictable positions

John Rose john.r.rose at oracle.com
Tue Mar 11 22:09:06 UTC 2014

On Mar 11, 2014, at 11:14 AM, Christian Thalinger <christian.thalinger at oracle.com> wrote:

>> Can you put () around the ?: expressions so I don't have to dig out my C++ manual to figure out order of operations in the getting and setting functions.

FTR, adding the parens is a good application of this bullet in the style guide:

	• Use extra parentheses in expressions whenever operator precedence seems doubtful. Always use parentheses in shift/mask expressions (<<, &, |, ~).

Ref: https://wiki.openjdk.java.net/display/HotSpot/StyleGuide#StyleGuide-Whitespace

(The unary "~" probably doesn't belong in the list.)

— John

More information about the hotspot-dev mailing list