New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 654707 link

Starred by 2 users

Issue metadata

Status: Fixed
Owner:
OoO until Feb 4th
Closed: Aug 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 740865



Sign in to add a comment

Make MessageEvent's ports attribute a non-nullable FrozenArray

Project Member Reported by foolip@chromium.org, Oct 11 2016

Issue description

Comment 1 by foolip@chromium.org, Oct 19 2016

Summary: Make MessageEvent's ports attribute a non-nullable FrozenArray (was: Make MessageEvent's ports attribute non-nullable)
Blocking: 740865
Cc: foolip@chromium.org
Owner: raphael....@intel.com
Status: Started (was: Assigned)
Taking over after talking to foolip on IRC. This is the last occurrence of WebIDL arrays in our IDL files.
Project Member

Comment 4 by bugdroid1@chromium.org, Aug 15 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966

commit 8ab32a6b63419f7a343f74bb3f4b173a9f3b4966
Author: Raphael Kubo da Costa <raphael.kubo.da.costa@intel.com>
Date: Tue Aug 15 23:55:39 2017

Make MessageEvent#ports a non-nullable FrozenArray.

WebIDL arrays were removed from the spec back in 2015, and this CL adapts to
https://github.com/whatwg/html/pull/863 ("Use FrozenArray for
Navigator#languages and MessageEvent#ports") as well as
https://github.com/whatwg/html/pull/1883 ("Make MessageEvent's ports
attribute non-nullable").

While here, also adapt to the part of the latter commit above that made
MessageEventInit#ports non-nullable.

The patch looks a bit longer than it would have been because we have to
cache MessageEvent#ports and return the same value until it's changed via
initMessageEvent().

Also update a few WPT tests which were written before |ports| was turned
into a FrozenArray: we now verify that attempting to change |ports| throws a
TypeError.

Bug:  654707 
Change-Id: I03c7aafc7e4148059cdbf5d75aa6c628c50ed05e
Reviewed-on: https://chromium-review.googlesource.com/612955
Commit-Queue: Raphael Kubo da Costa (rakuco) <raphael.kubo.da.costa@intel.com>
Reviewed-by: Philip Jägenstedt <foolip@chromium.org>
Reviewed-by: Kenichi Ishibashi <bashi@chromium.org>
Cr-Commit-Position: refs/heads/master@{#494614}
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/html/dom/interfaces-expected.txt
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/html/dom/interfaces.worker-expected.txt
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/scripting/events/messageevent-constructor.https-expected.txt
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/html/webappapis/scripting/events/messageevent-constructor.https.html
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/webmessaging/Channel_postMessage_ports_readonly_array.htm
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/external/wpt/workers/postMessage_ports_readonly_array.htm
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/fast/events/constructors/message-event-constructor-expected.txt
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/LayoutTests/fast/events/constructors/message-event-constructor.html
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/Source/core/events/MessageEvent.cpp
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/Source/core/events/MessageEvent.h
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/Source/core/events/MessageEvent.idl
[modify] https://crrev.com/8ab32a6b63419f7a343f74bb3f4b173a9f3b4966/third_party/WebKit/Source/core/events/MessageEventInit.idl

Labels: M-62
Status: Fixed (was: Started)

Sign in to add a comment