Re: [webIDL] nullable interface types

Dominique Hazael-Massieux:
> Arguably, this is something that can be fixed in the Contacts API, but
> before submitting the bug report, I was wondering what was the rationale
> for forbidding the use of "?" on interface types; in particular:
> • why interface types include the null value?
> • why is it forbidden to make nullable a type that already includes the
> null value?

I just chose null to be in the interface types because I thought it was
much more common to want reference values to be null than primitive
values.  There is certainly an argument for changing this.  The
alternative is to do something like what Anne has done in Web DOM Core,
and use [NoNull] annotations (or we could introduce an "!" after
interface names to “remove” null).  I’m open to opinions on which way to
go.

-- 
Cameron McCormack ≝ http://mcc.id.au/

Received on Friday, 8 October 2010 04:12:36 UTC