On Fri, 18 Sep 2026 22:45:55 GMT, Justin Lu <[email protected]> wrote:
> This PR corrects the output of > `HijrahChronology.INSTANCE.range(ChronoField.DAY_OF_YEAR).getSmallestMaximum()` > to reflect the true smallest maximum, 354. It currently returns 355. > > There are two separate concerns, > > In `loadCalendarData()`, the `minYearLength` uses its default value of 0 in > its `min` calculations, which ends up causing a `minYearLength` of 0. On top > of this, the `ValueRange` for `DAY_OF_YEAR` should use the 3-arg overload, > which allows passing `minYearLength`, so that the range can produce the > correct smallest max. > > Additionally, the `year < maxYear` conditional should be inclusive. Note that > fixing this boundary check does not actually have any observable behavioral > differences because the built-in Umm al-Qura calendar data consists of only > 354 and 355 days, which the many previous years already establish. > > --------- > - [x] I confirm that I make this contribution in accordance with the [OpenJDK > Interim AI Policy](https://openjdk.org/legal/ai). Thanks for the review. ------------- PR Comment: https://git.openjdk.org/jdk/pull/32958#issuecomment-5819534195
