RFR 8210285 : CharsetDecoder/Encoder's constructor does not reject NaN
Alan Bateman
Alan.Bateman at oracle.com
Mon Sep 3 10:57:18 UTC 2018
On 03/09/2018 05:54, Ivan Gerasimov wrote:
> Thanks Sherman and Stuart for the review!
>
> On 9/2/18 2:45 PM, Stuart Marks wrote:
>> Yes, the fix itself looks fine. Quite subtle, good catch.
>>
>> But should this have a regression test? I can imagine somebody coming
>> along later and "simplifying" (!(... > ...)) to (... <= ...) which
>> would reintroduce the bug.
>>
> Yes, there is a regression test added:
> http://cr.openjdk.java.net/~igerasim/8210285/00/webrev/test/jdk/java/nio/charset/CharsetDecoder/NaNinCtor.java.html
>
The update to Charset-X-Coder.java.template looks okay. The changes also
CharsetEncoder so we'll need test coverage for that too.
-Alan
More information about the core-libs-dev
mailing list