Bug 152583 - Intl.DateTimeFormat('en', null) should throw a TypeError
Summary: Intl.DateTimeFormat('en', null) should throw a TypeError
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: JavaScriptCore (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-12-29 02:06 PST by Sukolsak Sakshuwong
Modified: 2016-01-21 04:27 PST (History)
8 users (show)

See Also:


Attachments
Patch (4.55 KB, patch)
2015-12-29 02:13 PST, Sukolsak Sakshuwong
darin: review+
commit-queue: commit-queue-
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sukolsak Sakshuwong 2015-12-29 02:06:56 PST
According to ECMA-402 (2nd edition), 12.1.1, passing null as |options| to InitializeDateTimeFormat should throw a TypeError exception.

http://www.ecma-international.org/ecma-402/2.0/ECMA-402.pdf
Comment 1 Sukolsak Sakshuwong 2015-12-29 02:13:28 PST
Created attachment 267981 [details]
Patch
Comment 2 Andy VanWagoner 2015-12-29 07:50:50 PST
I had noticed that and also included the same fix in my patch for Date.prototype.toLocaleString(). https://bugs.webkit.org/show_bug.cgi?id=147611
Comment 3 Sukolsak Sakshuwong 2015-12-29 07:59:15 PST
(In reply to comment #2)
> I had noticed that and also included the same fix in my patch for
> Date.prototype.toLocaleString().
> https://bugs.webkit.org/show_bug.cgi?id=147611

Oops, sorry. I didn't see it. Please feel free to close this bug.
Comment 4 WebKit Commit Bot 2016-01-18 19:11:51 PST
Comment on attachment 267981 [details]
Patch

Rejecting attachment 267981 [details] from commit-queue.

Failed to run "['/Volumes/Data/EWS/WebKit/Tools/Scripts/webkit-patch', '--status-host=webkit-queues.webkit.org', '--bot-id=webkit-cq-01', 'apply-attachment', '--no-update', '--non-interactive', 267981, '--port=mac']" exit_code: 2 cwd: /Volumes/Data/EWS/WebKit

Last 500 characters of output:
l-datetimeformat-expected.txt
Hunk #1 FAILED at 82.
1 out of 1 hunk FAILED -- saving rejects to file LayoutTests/js/intl-datetimeformat-expected.txt.rej
patching file LayoutTests/js/script-tests/intl-datetimeformat.js
Hunk #1 FAILED at 162.
1 out of 1 hunk FAILED -- saving rejects to file LayoutTests/js/script-tests/intl-datetimeformat.js.rej

Failed to run "[u'/Volumes/Data/EWS/WebKit/Tools/Scripts/svn-apply', '--force', '--reviewer', u'Darin Adler']" exit_code: 1 cwd: /Volumes/Data/EWS/WebKit

Full output: http://webkit-queues.webkit.org/results/710243
Comment 5 Sukolsak Sakshuwong 2016-01-21 04:27:59 PST
This bug has been fixed in https://bugs.webkit.org/show_bug.cgi?id=147611