On Tue, 21 Jul 2026 20:13:02 GMT, Justin Lu <[email protected]> wrote:
>> This PR corrects two parsing issues for `DecimalFormat` during strict >> parsing. >> >> 1. The special parsing path for NaN was shared by lenient and strict >> parsing. As a result, subsequent text after the "NaN" was accepted in strict >> mode, although the trailing characters should have caused parsing to fail. >> Strict parsing needs to add additional logic for that special case. >> >> 2. In strict mode, a grouping size of zero causes all numeric input to be >> rejected since it tries to check for the first group immediately. A grouping >> size of zero is implies that grouping is not used. However, `isGroupingUsed` >> is independent of `setGroupingSize`. The implementation needs to check for >> both the int size and boolean status value when checking grouping during >> strict parsing. >> >> --------- >> - [x] I confirm that I make this contribution in accordance with the >> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai). > > Justin Lu has updated the pull request incrementally with one additional > commit since the last revision: > > Explicitly clarify the relationship between lenient and legacy parsing LGTM ------------- Marked as reviewed by naoto (Reviewer). PR Review: https://git.openjdk.org/jdk/pull/31980#pullrequestreview-4748913161
