Bug 211952

Summary: [JSC] Make OutOfMemory error as instance of RangeError
Product: WebKit Reporter: Yusuke Suzuki <ysuzuki>
Component: New BugsAssignee: Yusuke Suzuki <ysuzuki>
Status: RESOLVED FIXED    
Severity: Normal CC: ews-watchlist, keith_miller, mark.lam, msaboff, ross.kirsling, saam, tzagallo, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch
none
Patch none

Description Yusuke Suzuki 2020-05-15 05:50:42 PDT
[JSC] Make OutOfMemory error as instance of RangeError
Comment 1 Yusuke Suzuki 2020-05-15 05:51:19 PDT
Created attachment 399471 [details]
Patch

WIP
Comment 2 Yusuke Suzuki 2020-05-15 05:58:15 PDT
Created attachment 399472 [details]
Patch

WIP
Comment 3 Yusuke Suzuki 2020-05-15 11:02:26 PDT
Created attachment 399495 [details]
Patch
Comment 4 Yusuke Suzuki 2020-05-15 11:07:39 PDT
Created attachment 399497 [details]
Patch
Comment 5 Ross Kirsling 2020-05-15 16:54:57 PDT
Nice. Does this have any test262 impact?
Comment 6 Yusuke Suzuki 2020-05-15 18:50:29 PDT
Created attachment 399536 [details]
Patch
Comment 7 Yusuke Suzuki 2020-05-15 18:51:04 PDT
(In reply to Ross Kirsling from comment #5)
> Nice. Does this have any test262 impact?

Looks like no impact.
Comment 8 Mark Lam 2020-05-15 20:07:48 PDT
Comment on attachment 399536 [details]
Patch

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

r=me

> Source/JavaScriptCore/runtime/ErrorType.h:54
> +#define COUNT_ERROR_TYPES(name) 1 +
> +static constexpr unsigned NumberOfErrorType {
> +    JSC_ERROR_TYPES(COUNT_ERROR_TYPES) 0

Nice.  I never thought of doing it this way to do the counting.
Comment 9 EWS 2020-05-16 01:24:28 PDT
Committed r261780: <https://trac.webkit.org/changeset/261780>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 399536 [details].
Comment 10 Radar WebKit Bug Importer 2020-05-16 01:25:17 PDT
<rdar://problem/63302744>