Bug 101620

Summary: WebIDL: Incorrect type conversion for interface types
Product: WebKit Reporter: Erik Arvidsson <arv>
Component: DOMAssignee: Nobody <webkit-unassigned>
Status: NEW    
Severity: Normal CC: abarth, ap, haraken, jsbell, kangax
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
URL: http://www.w3.org/TR/WebIDL/#es-interface

Erik Arvidsson
Reported 2012-11-08 10:09:51 PST
If the operation argument is of type T, where T is an interface type (ie Node) we should throw a TypeError if the value is not a T. Currently we always convert this to null leading us to pass null into the webcore function. DOM spec: Node insertBefore(Node node, Node? child); WebKit IDL: If we call insertBefore(someNode, 42) we fail to convert 42 to a Node so we treat it as null which is not correct.
Attachments
Note You need to log in before you can comment on or make changes to this bug.