[OpenJDK 2D-Dev]  RFR: [JDK-8194489] Incorrect size computation at BandedSampleModel.createDataBuffer
Jayathirth D V
jayathirth.d.v at oracle.com
Wed Jan 10 12:00:29 UTC 2018
Change looks good to me.
From: Brian Burkhalter
Sent: Wednesday, January 10, 2018 6:52 AM
To: Prahalad Kumar Narayanan
Subject: Re: [OpenJDK 2D-Dev]  RFR: [JDK-8194489] Incorrect size computation at BandedSampleModel.createDataBuffer
On Jan 9, 2018, at 3:42 AM, Prahalad Kumar Narayanan <HYPERLINK "mailto:prahalad.kumar.narayanan at oracle.com"prahalad.kumar.narayanan at oracle.com> wrote:
L193-196 and 203-207: In general I think it's better for method-internal comments to use the "//" form instead of the "/*.*/" form.
. I find interspersed use of // and /* */ for multi-line comments in our client libs code.
. For example: The D3DBlitLoops uses "//" while many parts of Image IO use /* ... */ for multi-line comments.
. While implementing the fix, I try to maintain uniformity established by the file getting modified.
I think that is a good approach.
. In general, I refer to this guideline- http://cr.openjdk.java.net/~alundblad/styleguide/index-v6.html
For the record I tend to prefer the "//" for intra-method comments as I have found that not infrequently in debugging one needs to comment out a section and this is much easier to do if the comments in question do not use the "/*.*/" style. I think you can leave this one as-is however.
Instead of defining the utility methods compareSamples(int,int) and initSamples(int,int)
you might consider simply using j.u.Arrays.equals(int,int) and j.u.Arrays.fill(int,int), respectively.
. Thank you for the suggestion. It helped.
. I 've modified the test code to use Arrays.fill and Arrays.equals methods.
The modified code is now available for review under
Kindly review at your convenience and share your thoughts.
I think this looks OK.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the 2d-dev