- From: Tab Atkins Jr. <notifications@github.com>
- Date: Thu, 11 Mar 2021 10:12:44 -0800
- To: heycam/webidl <webidl@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
Received on Thursday, 11 March 2021 18:12:57 UTC
Looking over the remaining spots where `undefined` is mentioned, I'm not entirely sure what to do about the "convert an ES value to an IDL union type" part, and I think it raises questions about distinguishability too: > If V is null or undefined, then: > > * If types includes a dictionary type, then return the result of converting V to that dictionary type. So this implies that the current behavior is that a JS `undefined` can always be converted into a dictionary type. I presume this is fallout from the fact that dictionary *arguments* are required to be optional. Does this imply that `undefined` and dictionary types should not be distinguishable, tho? Or is it okay for them to remain distinguishable, so I'll add a new first step that checks if the union type contains `undefined`, and then the dictionary conversion is a fallback? (Also, hm, all of the 3.2.24 algo confuses me, since it's composed of nested conditionals where the inner conditionals don't have "else" clauses. Is the implication that you continue to next top-level step if you fail all the conditions?) -- 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/962#issuecomment-796938662
Received on Thursday, 11 March 2021 18:12:57 UTC