RESOLVED FIXED158544
DedicatedWorkerGlobalScope prototype chain is incorrect
https://bugs.webkit.org/show_bug.cgi?id=158544
Summary DedicatedWorkerGlobalScope prototype chain is incorrect
Chris Dumez
Reported 2016-06-08 15:00:06 PDT
WorkerGlobalScope.prototype is [object DedicatedWorkerGlobalScopePrototype] but should be [object WorkerGlobalScopePrototype]. This is causing failures on: http://w3c-test.org/workers/interfaces.worker
Attachments
WIP Patch (4.80 KB, patch)
2016-06-08 16:57 PDT, Chris Dumez
no flags
Patch (11.41 KB, patch)
2016-06-08 20:53 PDT, Chris Dumez
no flags
Chris Dumez
Comment 1 2016-06-08 15:04:26 PDT
Seems related to this in the bindings generator: if (IsDOMGlobalObject($interface)) { push(@$outputArray, " putDirect(vm, vm.propertyNames->prototype, globalObject.getPrototypeDirect(), DontDelete | ReadOnly | DontEnum);\n"); IsDOMGlobalObject() returns true for both WorkerGlobalScope and DedicatedWorkerGlobalScope.
Chris Dumez
Comment 2 2016-06-08 16:57:09 PDT
Created attachment 280856 [details] WIP Patch
Chris Dumez
Comment 3 2016-06-08 18:23:29 PDT
Expected: DedicatedWorkerGlobalScope.prototype.toString() === "[object DedicatedWorkerGlobalScopePrototype]": true Object.getPrototypeOf(DedicatedWorkerGlobalScope.prototype) === WorkerGlobalScope.prototype: true WorkerGlobalScope.prototype.toString() === "[object WorkerGlobalScopePrototype]": true Object.getPrototypeOf(WorkerGlobalScope.prototype) === EventTarget.prototype: true But got: DedicatedWorkerGlobalScope.prototype.toString() === "[object DedicatedWorkerGlobalScopePrototype]": true Object.getPrototypeOf(DedicatedWorkerGlobalScope.prototype) === WorkerGlobalScope.prototype: false WorkerGlobalScope.prototype.toString() === "[object WorkerGlobalScopePrototype]": false Object.getPrototypeOf(WorkerGlobalScope.prototype) === EventTarget.prototype: false
Chris Dumez
Comment 4 2016-06-08 20:53:01 PDT
WebKit Commit Bot
Comment 5 2016-06-08 22:17:09 PDT
Comment on attachment 280879 [details] Patch Clearing flags on attachment: 280879 Committed r201852: <http://trac.webkit.org/changeset/201852>
WebKit Commit Bot
Comment 6 2016-06-08 22:17:14 PDT
All reviewed patches have been landed. Closing bug.
Note You need to log in before you can comment on or make changes to this bug.