WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
174140
[WebIDL] Convert MutationCallback to be a normal generated callback
https://bugs.webkit.org/show_bug.cgi?id=174140
Summary
[WebIDL] Convert MutationCallback to be a normal generated callback
Sam Weinig
Reported
2017-07-04 14:17:35 PDT
[WebIDL] Convert MutationCallback to be a normal generate callback
Attachments
Patch
(31.87 KB, patch)
2017-07-04 14:27 PDT
,
Sam Weinig
no flags
Details
Formatted Diff
Diff
Archive of layout-test-results from ews101 for mac-elcapitan
(1.03 MB, application/zip)
2017-07-04 15:44 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews104 for mac-elcapitan-wk2
(1.08 MB, application/zip)
2017-07-04 15:48 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews123 for ios-simulator-wk2
(6.29 MB, application/zip)
2017-07-04 16:18 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews112 for mac-elcapitan
(1.79 MB, application/zip)
2017-07-04 17:39 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews117 for mac-elcapitan
(1.78 MB, application/zip)
2017-07-04 19:40 PDT
,
Build Bot
no flags
Details
Patch
(68.50 KB, patch)
2017-07-05 22:53 PDT
,
Sam Weinig
no flags
Details
Formatted Diff
Diff
Archive of layout-test-results from ews103 for mac-elcapitan
(984.87 KB, application/zip)
2017-07-05 23:59 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews106 for mac-elcapitan-wk2
(1.14 MB, application/zip)
2017-07-06 00:05 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews122 for ios-simulator-wk2
(948.22 KB, application/zip)
2017-07-06 00:28 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews114 for mac-elcapitan
(1.83 MB, application/zip)
2017-07-06 01:47 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews112 for mac-elcapitan
(1.78 MB, application/zip)
2017-07-06 03:50 PDT
,
Build Bot
no flags
Details
Patch
(73.15 KB, patch)
2017-07-06 15:22 PDT
,
Sam Weinig
no flags
Details
Formatted Diff
Diff
Patch
(110.46 KB, patch)
2017-08-02 14:58 PDT
,
Sam Weinig
no flags
Details
Formatted Diff
Diff
Patch
(116.87 KB, patch)
2017-08-02 15:54 PDT
,
Sam Weinig
no flags
Details
Formatted Diff
Diff
Archive of layout-test-results from ews101 for mac-elcapitan
(1.10 MB, application/zip)
2017-08-02 17:00 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews121 for ios-simulator-wk2
(959.74 KB, application/zip)
2017-08-02 17:46 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews107 for mac-elcapitan-wk2
(1.42 MB, application/zip)
2017-08-02 18:08 PDT
,
Build Bot
no flags
Details
Archive of layout-test-results from ews117 for mac-elcapitan
(1.85 MB, application/zip)
2017-08-02 18:48 PDT
,
Build Bot
no flags
Details
Patch
(113.59 KB, patch)
2017-08-02 20:20 PDT
,
Sam Weinig
darin
: review+
Details
Formatted Diff
Diff
Show Obsolete
(19)
View All
Add attachment
proposed patch, testcase, etc.
Sam Weinig
Comment 1
2017-07-04 14:27:42 PDT
Comment hidden (obsolete)
Created
attachment 314579
[details]
Patch
Build Bot
Comment 2
2017-07-04 15:44:11 PDT
Comment hidden (obsolete)
Comment on
attachment 314579
[details]
Patch
Attachment 314579
[details]
did not pass mac-ews (mac): Output:
http://webkit-queues.webkit.org/results/4052871
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html fast/dom/MutationObserver/callback-arguments.html
Build Bot
Comment 3
2017-07-04 15:44:12 PDT
Comment hidden (obsolete)
Created
attachment 314581
[details]
Archive of layout-test-results from ews101 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews101 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Build Bot
Comment 4
2017-07-04 15:48:57 PDT
Comment hidden (obsolete)
Comment on
attachment 314579
[details]
Patch
Attachment 314579
[details]
did not pass mac-wk2-ews (mac-wk2): Output:
http://webkit-queues.webkit.org/results/4052878
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html fast/dom/MutationObserver/callback-arguments.html
Build Bot
Comment 5
2017-07-04 15:48:58 PDT
Comment hidden (obsolete)
Created
attachment 314582
[details]
Archive of layout-test-results from ews104 for mac-elcapitan-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews104 Port: mac-elcapitan-wk2 Platform: Mac OS X 10.11.6
Build Bot
Comment 6
2017-07-04 16:18:09 PDT
Comment hidden (obsolete)
Comment on
attachment 314579
[details]
Patch
Attachment 314579
[details]
did not pass ios-sim-ews (ios-simulator-wk2): Output:
http://webkit-queues.webkit.org/results/4052904
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html fast/dom/MutationObserver/callback-arguments.html
Build Bot
Comment 7
2017-07-04 16:18:11 PDT
Comment hidden (obsolete)
Created
attachment 314584
[details]
Archive of layout-test-results from ews123 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews123 Port: ios-simulator-wk2 Platform: Mac OS X 10.12.5
Build Bot
Comment 8
2017-07-04 17:39:13 PDT
Comment hidden (obsolete)
Comment on
attachment 314579
[details]
Patch
Attachment 314579
[details]
did not pass mac-debug-ews (mac): Output:
http://webkit-queues.webkit.org/results/4053080
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html fast/dom/MutationObserver/callback-arguments.html
Build Bot
Comment 9
2017-07-04 17:39:14 PDT
Comment hidden (obsolete)
Created
attachment 314587
[details]
Archive of layout-test-results from ews112 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews112 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Build Bot
Comment 10
2017-07-04 19:40:16 PDT
Comment hidden (obsolete)
Comment on
attachment 314579
[details]
Patch
Attachment 314579
[details]
did not pass mac-debug-ews (mac): Output:
http://webkit-queues.webkit.org/results/4053553
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html fast/dom/MutationObserver/callback-arguments.html
Build Bot
Comment 11
2017-07-04 19:40:17 PDT
Comment hidden (obsolete)
Created
attachment 314592
[details]
Archive of layout-test-results from ews117 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews117 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Sam Weinig
Comment 12
2017-07-05 10:46:28 PDT
I need to come up with a way to pass a this object to a callback. I have two ideas. 1) Add a setThisObject(...) function that the callback needs to implement which should be called before handleEvent(). 2) For callbacks that need a this object, pass it as the first argument, and offset the rest of the arguments by one. I think I am leaning toward the second option.
Sam Weinig
Comment 13
2017-07-05 22:53:56 PDT
Comment hidden (obsolete)
Created
attachment 314697
[details]
Patch
Build Bot
Comment 14
2017-07-05 23:59:18 PDT
Comment hidden (obsolete)
Comment on
attachment 314697
[details]
Patch
Attachment 314697
[details]
did not pass mac-ews (mac): Output:
http://webkit-queues.webkit.org/results/4061218
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html
Build Bot
Comment 15
2017-07-05 23:59:19 PDT
Comment hidden (obsolete)
Created
attachment 314700
[details]
Archive of layout-test-results from ews103 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews103 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Build Bot
Comment 16
2017-07-06 00:05:31 PDT
Comment hidden (obsolete)
Comment on
attachment 314697
[details]
Patch
Attachment 314697
[details]
did not pass mac-wk2-ews (mac-wk2): Output:
http://webkit-queues.webkit.org/results/4061223
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html
Build Bot
Comment 17
2017-07-06 00:05:33 PDT
Comment hidden (obsolete)
Created
attachment 314701
[details]
Archive of layout-test-results from ews106 for mac-elcapitan-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews106 Port: mac-elcapitan-wk2 Platform: Mac OS X 10.11.6
Build Bot
Comment 18
2017-07-06 00:28:07 PDT
Comment hidden (obsolete)
Comment on
attachment 314697
[details]
Patch
Attachment 314697
[details]
did not pass ios-sim-ews (ios-simulator-wk2): Output:
http://webkit-queues.webkit.org/results/4061232
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html
Build Bot
Comment 19
2017-07-06 00:28:08 PDT
Comment hidden (obsolete)
Created
attachment 314705
[details]
Archive of layout-test-results from ews122 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews122 Port: ios-simulator-wk2 Platform: Mac OS X 10.12.5
Build Bot
Comment 20
2017-07-06 01:47:02 PDT
Comment hidden (obsolete)
Comment on
attachment 314697
[details]
Patch
Attachment 314697
[details]
did not pass mac-debug-ews (mac): Output:
http://webkit-queues.webkit.org/results/4061376
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html
Build Bot
Comment 21
2017-07-06 01:47:04 PDT
Comment hidden (obsolete)
Created
attachment 314712
[details]
Archive of layout-test-results from ews114 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews114 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Build Bot
Comment 22
2017-07-06 03:50:28 PDT
Comment hidden (obsolete)
Comment on
attachment 314697
[details]
Patch
Attachment 314697
[details]
did not pass mac-debug-ews (mac): Output:
http://webkit-queues.webkit.org/results/4061886
New failing tests: fast/dom/MutationObserver/mutation-observer-constructor.html
Build Bot
Comment 23
2017-07-06 03:50:29 PDT
Comment hidden (obsolete)
Created
attachment 314717
[details]
Archive of layout-test-results from ews112 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews112 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Sam Weinig
Comment 24
2017-07-06 15:22:20 PDT
Created
attachment 314762
[details]
Patch
Chris Dumez
Comment 25
2017-07-09 10:20:28 PDT
Comment on
attachment 314762
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=314762&action=review
r=me
> Source/WebCore/ChangeLog:3 > + [WebIDL] Convert MutationCallback to be a normal generate callback
"normal generate callback" ?
> Source/WebCore/ChangeLog:9 > + - Added the ability to for non-nullable interfaces in sequences to be passed
"to for"?
Sam Weinig
Comment 26
2017-07-11 14:07:11 PDT
Committed
r219361
: <
http://trac.webkit.org/changeset/219361
>
WebKit Commit Bot
Comment 27
2017-07-12 13:39:48 PDT
Re-opened since this is blocked by
bug 174434
Sam Weinig
Comment 28
2017-08-02 14:58:34 PDT
Comment hidden (obsolete)
Created
attachment 317007
[details]
Patch
Build Bot
Comment 29
2017-08-02 15:51:42 PDT
Comment hidden (obsolete)
Comment on
attachment 317007
[details]
Patch
Attachment 317007
[details]
did not pass bindings-ews (mac): Output:
http://webkit-queues.webkit.org/results/4242339
New failing tests: (JS) JSTestCallbackFunction.cpp (JS) JSTestCallbackFunction.h (JS) JSTestCallbackFunctionRethrow.cpp (JS) JSTestCallbackFunctionRethrow.h (JS) JSTestCallbackFunctionWithThisObject.cpp (JS) JSTestCallbackFunctionWithThisObject.h (JS) JSTestCallbackFunctionWithTypedefs.cpp (JS) JSTestCallbackFunctionWithTypedefs.h (JS) JSTestCallbackInterface.cpp (JS) JSTestCallbackInterface.h (JS) JSTestVoidCallbackFunction.cpp (JS) JSTestVoidCallbackFunction.h
Sam Weinig
Comment 30
2017-08-02 15:54:53 PDT
Comment hidden (obsolete)
Created
attachment 317020
[details]
Patch
Build Bot
Comment 31
2017-08-02 17:00:12 PDT
Comment hidden (obsolete)
Comment on
attachment 317020
[details]
Patch
Attachment 317020
[details]
did not pass mac-ews (mac): Output:
http://webkit-queues.webkit.org/results/4242541
New failing tests: imported/w3c/web-platform-tests/cssom-view/matchMedia.xht
Build Bot
Comment 32
2017-08-02 17:00:14 PDT
Comment hidden (obsolete)
Created
attachment 317032
[details]
Archive of layout-test-results from ews101 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-ews. Bot: ews101 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Build Bot
Comment 33
2017-08-02 17:46:03 PDT
Comment hidden (obsolete)
Comment on
attachment 317020
[details]
Patch
Attachment 317020
[details]
did not pass ios-sim-ews (ios-simulator-wk2): Output:
http://webkit-queues.webkit.org/results/4242672
New failing tests: imported/w3c/web-platform-tests/cssom-view/matchMedia.xht
Build Bot
Comment 34
2017-08-02 17:46:04 PDT
Comment hidden (obsolete)
Created
attachment 317046
[details]
Archive of layout-test-results from ews121 for ios-simulator-wk2 The attached test failures were seen while running run-webkit-tests on the ios-sim-ews. Bot: ews121 Port: ios-simulator-wk2 Platform: Mac OS X 10.12.5
Build Bot
Comment 35
2017-08-02 18:08:19 PDT
Comment hidden (obsolete)
Comment on
attachment 317020
[details]
Patch
Attachment 317020
[details]
did not pass mac-wk2-ews (mac-wk2): Output:
http://webkit-queues.webkit.org/results/4242901
New failing tests: imported/w3c/web-platform-tests/cssom-view/matchMedia.xht
Build Bot
Comment 36
2017-08-02 18:08:21 PDT
Comment hidden (obsolete)
Created
attachment 317053
[details]
Archive of layout-test-results from ews107 for mac-elcapitan-wk2 The attached test failures were seen while running run-webkit-tests on the mac-wk2-ews. Bot: ews107 Port: mac-elcapitan-wk2 Platform: Mac OS X 10.11.6
Build Bot
Comment 37
2017-08-02 18:48:40 PDT
Comment hidden (obsolete)
Comment on
attachment 317020
[details]
Patch
Attachment 317020
[details]
did not pass mac-debug-ews (mac): Output:
http://webkit-queues.webkit.org/results/4243086
New failing tests: imported/w3c/web-platform-tests/cssom-view/matchMedia.xht
Build Bot
Comment 38
2017-08-02 18:48:41 PDT
Comment hidden (obsolete)
Created
attachment 317060
[details]
Archive of layout-test-results from ews117 for mac-elcapitan The attached test failures were seen while running run-webkit-tests on the mac-debug-ews. Bot: ews117 Port: mac-elcapitan Platform: Mac OS X 10.11.6
Sam Weinig
Comment 39
2017-08-02 20:20:07 PDT
Created
attachment 317077
[details]
Patch
Darin Adler
Comment 40
2017-08-03 09:44:17 PDT
Comment on
attachment 317077
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=317077&action=review
> Source/WebCore/ChangeLog:3 > + [WebIDL] Convert MutationCallback to be a normal generate callback
generated?
> Source/WebCore/Modules/geolocation/PositionCallback.h:38 > + using ActiveDOMCallback::ActiveDOMCallback;
What does this do? I have never seen this syntax before; it looks like it would make a base class constructor public, but I not know what that means. And also, it seems that since we inherit from ActiveDOMCallback publicly that it would already be public, so what is this for?
> Source/WebCore/Modules/geolocation/PositionCallback.h:40 > virtual ~PositionCallback() { }
This is no longer needed now that we have a base class that already makes the detstructor virtual.
> Source/WebCore/Modules/geolocation/PositionCallback.h:41 > virtual CallbackResult<void> handleEvent(Geoposition*) = 0;
Wish this was a reference instead of a pointer.
> Source/WebCore/Modules/geolocation/PositionErrorCallback.h:40 > + using ActiveDOMCallback::ActiveDOMCallback; > + > virtual ~PositionErrorCallback() { }
Ditto. Same for all the other classes.
Sam Weinig
Comment 41
2017-08-03 09:57:55 PDT
(In reply to Darin Adler from
comment #40
)
> Comment on
attachment 317077
[details]
> Patch > > View in context: >
https://bugs.webkit.org/attachment.cgi?id=317077&action=review
> > > Source/WebCore/ChangeLog:3 > > + [WebIDL] Convert MutationCallback to be a normal generate callback > > generated?
Yep. Will fix.
> > > Source/WebCore/Modules/geolocation/PositionCallback.h:38 > > + using ActiveDOMCallback::ActiveDOMCallback; > > What does this do? I have never seen this syntax before; it looks like it > would make a base class constructor public, but I not know what that means. > And also, it seems that since we inherit from ActiveDOMCallback publicly > that it would already be public, so what is this for?
It adds all the constructors from ActiveDOMCallback to, in this case, PositionCallback. I found the section called "Inheriting constructors" in
http://en.cppreference.com/w/cpp/language/using_declaration
useful and interesting.
> > > Source/WebCore/Modules/geolocation/PositionCallback.h:40 > > virtual ~PositionCallback() { } > > This is no longer needed now that we have a base class that already makes > the detstructor virtual.
Good point, will remove.
> > > Source/WebCore/Modules/geolocation/PositionCallback.h:41 > > virtual CallbackResult<void> handleEvent(Geoposition*) = 0; > > Wish this was a reference instead of a pointer.
Me too. :(.
Sam Weinig
Comment 42
2017-08-03 10:51:24 PDT
Committed
r220210
: <
http://trac.webkit.org/changeset/220210
>
Radar WebKit Bug Importer
Comment 43
2017-08-03 10:52:26 PDT
<
rdar://problem/33703510
>
Chris Dumez
Comment 44
2017-08-24 16:19:59 PDT
The changes to MutationObserver / MutationCallback may have caused crashes (
rdar://problem/34062022
).
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug