- From: Domenic Denicola <notifications@github.com>
- Date: Wed, 03 Apr 2019 09:06:27 -0700
- To: heycam/webidl <webidl@noreply.github.com>
- Cc: Subscribed <subscribed@noreply.github.com>
- Message-ID: <heycam/webidl/pull/700/review/222302611@github.com>
domenic commented on this pull request.
Overall looks good; a few minor things to resolve.
In regard to ecosystem impact, what I'd really like to do is have a checklist of all specs to update. How long it takes us to update is less crucial to me, but having a corpus of all [Constructor]-using IDL and a list of specs we need to send PRs to would be a good idea.
@foolip or his team may know the latest on the "canonical IDL corpus" story?
> @@ -2540,6 +2542,82 @@ in which case the [=default toJSON operation=] is exposed instead.
</div>
+<h4 id=idl-constructors oldids="Constructor" dfn>Constructor methods</h4>
"Constructor method" is a weird term. I usually think of constructors and methods as disjoint sets. Could we call these "constructors" or, if we really need a term of art, perhaps "constructor operations"?
> + Node item(unsigned long index);
+ readonly attribute unsigned long length;
+ };
+
+ [Exposed=Window]
+ interface Circle {
+ constructor();
+ constructor(double radius);
+ attribute double r;
+ attribute double cx;
+ attribute double cy;
+ readonly attribute double circumference;
+ };
+ </pre>
+
+ An ECMAScript implementation supporting these interfaces would have a \[[Construct]] property
```suggestion
An ECMAScript implementation supporting these interfaces would implement a \[[Construct]] internal method
```
> + interface Circle {
+ constructor();
+ constructor(double radius);
+ attribute double r;
+ attribute double cx;
+ attribute double cy;
+ readonly attribute double circumference;
+ };
+ </pre>
+
+ An ECMAScript implementation supporting these interfaces would have a \[[Construct]] property
+ on the <code class="idl">Circle</code> interface object which would return a new object that
+ [=implements=] the interface.
+ It would take either zero or one argument.
+ The <code class="idl">NodeList</code> interface object would not have a \[[Construct]]
+ property.
We should either have this be an XXX unclear box, or block this on resolving #698.
--
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/pull/700#pullrequestreview-222302611
Received on Wednesday, 3 April 2019 16:06:50 UTC