W3C home > Mailing lists > Public > public-script-coord@w3.org > July to September 2015

Re: in webIDL can a required dictionary member be nullable?

From: Tab Atkins Jr. <jackalmage@gmail.com>
Date: Thu, 16 Jul 2015 16:50:55 -0700
Message-ID: <CAAWBYDD_sNQi6hSAw9zQwWA1y4ovqiBM-wqyinjLiq7Gcz0tGg@mail.gmail.com>
To: "=JeffH" <Jeff.Hodges@kingsmountain.com>
Cc: "public-script-coord@w3.org" <public-script-coord@w3.org>
On Thu, Jul 16, 2015 at 4:49 PM, =JeffH <Jeff.Hodges@kingsmountain.com> wrote:
> Hi folks, I have a quick hopefully easy question I just need to
> double-check on..
>
> in webIDL 2nd Ed. [1] can a required dictionary member be nullable?
>
> e.g.  can one do this..
>
>   dictionary foo {
>     required DOMString? bar;
>     required DOMString? baz;
>   };
>
> ..?
>
> From my reading of [1], especially at [2], the answer is "yes" for the
> case of such a dictionary, correct?

Absolutely. null is a value.

~TJ
Received on Thursday, 16 July 2015 23:51:42 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 16 July 2015 23:51:43 UTC