Skip to content

Commit 1c694dd

Browse files
Ms2gerptomato
authored andcommitted
Editorial: Clarify Infinity handling in PlainDate constructor.
1 parent 3e6cd50 commit 1c694dd

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/plaindate.mjs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,9 @@ const DISALLOWED_UNITS = ['hour', 'minute', 'second', 'millisecond', 'microsecon
2222

2323
export class PlainDate {
2424
constructor(isoYear, isoMonth, isoDay, calendar = ES.GetISO8601Calendar()) {
25-
isoYear = ES.ToInteger(isoYear);
26-
isoMonth = ES.ToInteger(isoMonth);
27-
isoDay = ES.ToInteger(isoDay);
25+
isoYear = ES.ToFiniteInteger(isoYear);
26+
isoMonth = ES.ToFiniteInteger(isoMonth);
27+
isoDay = ES.ToFiniteInteger(isoDay);
2828
calendar = ES.ToTemporalCalendar(calendar);
2929

3030
// Note: if the arguments are not passed, ToInteger(undefined) will have returned 0, which will

0 commit comments

Comments
 (0)