Re: [heycam/webidl] A non-optional dictionary argument makes sense at times. (#130)

> "CONVENTION: if an empty argument won't cause a TypeError, the argument MUST be marked Optional, to inform the user that an empty argument and an omitted argument has the same result"

The IDL layer has no way to tell whether an empty argument will cause a TypeError.  How would this convention actually be enforced in practice?

But more to the point, for dictionaries the idea is that an empty argument and an omitted argument _always_ has the same result.  This doesn't depend on whether the empty argument causes a TypeError or not.

I assume you meant `optional` whenever you wrote `?`.

---
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/heycam/webidl/issues/130#issuecomment-226245204

Received on Wednesday, 15 June 2016 16:38:25 UTC