Re: [IDL] rationale for undefined -> null in nullable types

Anne van Kesteren:
> We were wondering what the rationale is for treating undefined identical
> to null in nullable types. The change happened over 10 months ago, but
> there does not appear to be related mailing list discussed.
>
> http://dev.w3.org/cvsweb/2006/webapi/WebIDL/Overview.xml?f=h;rev=1.295

I think undefined needs to be treated as null, at least with the current 
formulations of various DOM operations.  Something like:

   <!DOCTYPE html>
   <body><span>hello </span>
   <script>
   var n = document.createTextNode("there");
   document.body.insertBefore(n, undefined);
   </script>

needs to behave the same as insertBefore(n, null).

Received on Wednesday, 16 May 2012 23:40:10 UTC