Bug 236936 - [JSC] Temporal.PlainDate should validate input range
Summary: [JSC] Temporal.PlainDate should validate input range
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Yusuke Suzuki
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2022-02-20 01:41 PST by Yusuke Suzuki
Modified: 2022-02-21 18:13 PST (History)
11 users (show)

See Also:


Attachments
Patch (11.80 KB, patch)
2022-02-20 01:46 PST, Yusuke Suzuki
no flags Details | Formatted Diff | Diff
Patch (14.28 KB, patch)
2022-02-21 14:44 PST, Yusuke Suzuki
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (14.98 KB, patch)
2022-02-21 14:54 PST, Yusuke Suzuki
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (14.57 KB, patch)
2022-02-21 15:09 PST, Yusuke Suzuki
darin: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Yusuke Suzuki 2022-02-20 01:41:22 PST
[JSC] Temporal.PlainDate should validate input range
Comment 1 Yusuke Suzuki 2022-02-20 01:46:16 PST
Created attachment 452687 [details]
Patch
Comment 2 Darin Adler 2022-02-21 12:57:42 PST
Comment on attachment 452687 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=452687&action=review

> JSTests/ChangeLog:3
> +        [JSC] Temporal.PlainDate should validate input range

I think we’d want the test for the last valid as well as the first invalid.
Comment 3 Yusuke Suzuki 2022-02-21 14:43:50 PST
Comment on attachment 452687 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=452687&action=review

>> JSTests/ChangeLog:3
>> +        [JSC] Temporal.PlainDate should validate input range
> 
> I think we’d want the test for the last valid as well as the first invalid.

Sounds good, added.
Comment 4 Yusuke Suzuki 2022-02-21 14:44:26 PST
Created attachment 452776 [details]
Patch
Comment 5 Yusuke Suzuki 2022-02-21 14:54:48 PST
Created attachment 452778 [details]
Patch
Comment 6 Yusuke Suzuki 2022-02-21 15:09:27 PST
Created attachment 452781 [details]
Patch
Comment 7 Darin Adler 2022-02-21 16:58:25 PST
Comment on attachment 452781 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=452781&action=review

review+ assuming the tests pass

> JSTests/stress/temporal-plaindate.js:114
> +new Temporal.PlainDate(0x43530, 9, 13);

Maybe a shouldBe about the string form?

> JSTests/stress/temporal-plaindate.js:116
> +new Temporal.PlainDate(-0x425cd, 4, 20);

Ditto.
Comment 8 Yusuke Suzuki 2022-02-21 18:07:50 PST
Comment on attachment 452781 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=452781&action=review

Thank you!

>> JSTests/stress/temporal-plaindate.js:114
>> +new Temporal.PlainDate(0x43530, 9, 13);
> 
> Maybe a shouldBe about the string form?

Done.

>> JSTests/stress/temporal-plaindate.js:116
>> +new Temporal.PlainDate(-0x425cd, 4, 20);
> 
> Ditto.

Done.
Comment 9 Yusuke Suzuki 2022-02-21 18:12:32 PST
Committed r290282 (?): <https://commits.webkit.org/r290282>
Comment 10 Radar WebKit Bug Importer 2022-02-21 18:13:15 PST
<rdar://problem/89268246>