RESOLVED DUPLICATE of bug 160394 160385
Drop [StrictTypeChecking] support for operation parameters of DOMString / enumeration types
https://bugs.webkit.org/show_bug.cgi?id=160385
Summary Drop [StrictTypeChecking] support for operation parameters of DOMString / enu...
Chris Dumez
Reported 2016-07-30 17:28:35 PDT
Drop [StrictTypeChecking] support for operation parameters of DOMString / enumeration types. Using [StrictTypeChecking] would cause us to throw a TypeError if the value passed by JS is not null / undefined / a string / an object. This behavior is non-standard as the WebIDL says we should merely call ToString() on the value: - http://heycam.github.io/webidl/#es-DOMString - http://heycam.github.io/webidl/#es-enumeration
Attachments
Chris Dumez
Comment 1 2016-07-30 17:34:32 PDT
It looks like this is used only for the following overloaded operations to help with overload resolution: Source/WebCore/html/canvas/CanvasRenderingContext2D.idl: void setStrokeColor([StrictTypeChecking] DOMString color, optional unrestricted float alpha); Source/WebCore/html/canvas/CanvasRenderingContext2D.idl: void setFillColor([StrictTypeChecking] DOMString color, optional unrestricted float alpha); I will find a better way to implement this without requiring an additional IDL attribute.
Chris Dumez
Comment 2 2016-08-01 14:05:33 PDT
Chris Dumez
Comment 3 2016-08-02 10:07:59 PDT
*** This bug has been marked as a duplicate of bug 160394 ***
Note You need to log in before you can comment on or make changes to this bug.