diff --git a/index.bs b/index.bs index 3ea815ed..5722a16c 100644 --- a/index.bs +++ b/index.bs @@ -3174,7 +3174,7 @@ represents the allowable invocations for a particular constructor (specified with [{{Constructor}}] or [{{NamedConstructor}}]), or [=callback function=]. -The algorithm to compute an [=effective overload set=] +The algorithm to [=compute the effective overload set=] operates on one of the following four types of IDL constructs, and listed with them below are the inputs to the algorithm needed to compute the set. @@ -3191,8 +3191,8 @@ the inputs to the algorithm needed to compute the set. * the [=identifier=] of the named constructors * the number of arguments to be passed -An effective overload set is used, among other things, to determine whether there are ambiguities in the -overloaded operations and constructors specified on an interface. +An [=effective overload set=] is used, among other things, to determine whether there are +ambiguities in the overloaded operations and constructors specified on an interface. The [=set/items=] of an [=effective overload set=] are [=tuples=] of the form ([=effective overload set tuple/callable=], [=type list=], [=optionality list=]) @@ -3213,11 +3213,11 @@ Each [=tuple=] represents an allowable invocation of the operation, constructor, or callback function with an argument value list of the given types. Due to the use of [=optional arguments=] and [=variadic=] operations -and constructors, there may be multiple items in an effective overload set identifying +and constructors, there may be multiple items in an [=effective overload set=] identifying the same operation or constructor. -
- The algorithm below describes how to compute an effective overload set. +
+ The algorithm below describes how to compute the effective overload set. The following input variables are used, if they are required: * the identifier of the operation or named constructor is |A| @@ -3230,7 +3230,7 @@ the same operation or constructor. 1. Let |S| be an [=ordered set=]. 1. Let |F| be an [=ordered set=] with [=set/items=] as follows, - according to the kind of effective overload set: + according to the kind of [=effective overload set=]:
: For regular operations :: The elements of |F| are the [=regular operations=] with @@ -3599,11 +3599,11 @@ that has a given [=type list=] [=list/size=], then for those items there must be an index |i| such that for each pair of items the types at index |i| are [=distinguishable=]. The lowest such index is termed the distinguishing argument index -for the items of the effective overload set with the given type list size. +for the items of the [=effective overload set=] with the given type list size.
- Consider the effective overload set shown in the previous example. + Consider the [=effective overload set=] shown in the previous example. There are multiple items in the set with type lists 2, 3 and 4. For each of these type list size, the [=distinguishing argument index=] is 0, since Node and Event are [=distinguishable=]. @@ -3642,7 +3642,7 @@ be the same. }; - For argument count 4, the effective overload set is: + For argument count 4, the [=effective overload set=] is:
       «
@@ -10651,9 +10651,8 @@ the typeof operator will return "function" when applied to an inter
         1.  Let |args| be the passed arguments.
         1.  Let |n| be the [=list/size=] of |args|.
         1.  Let |id| be the identifier of interface |I|.
-        1.  Initialize |S| to the [=effective overload set=]
-            for constructors with [=identifier=] |id|
-            on [=interface=] |I| and with argument count |n|.
+        1.  [=Compute the effective overload set=] for constructors with [=identifier=] |id| on
+            [=interface=] |I| and with argument count |n|, and let |S| be the result.
         1.  Let <|constructor|, |values|> be the result
             of passing |S| and |args|.
             to the [=overload resolution algorithm=].
@@ -10684,9 +10683,8 @@ the typeof operator will return "function" when applied to an inter
     1.  Perform [=!=] SetFunctionName(|F|, |id|).
     1.  Let |length| be 0.
     1.  If |I| was declared with a [{{Constructor}}] [=extended attribute=], then
-        1.  Initialize |S| to the [=effective overload set=]
-            for constructors with [=identifier=] |id| on [=interface=] |I| and
-            with argument count 0.
+        1.  [=Compute the effective overload set=] for constructors with [=identifier=] |id| on
+            [=interface=] |I| and with argument count 0, and let |S| be the result.
         1.  Set |length| to the length of the
             shortest argument list of the entries in |S|.
     1.  Perform [=!=] SetFunctionLength(|F|, |length|).
@@ -10722,9 +10720,8 @@ implement the interface on which the
             [=ECMAScript/throw=] a {{ECMAScript/TypeError}}.
         1.  Let |args| be the passed arguments.
         1.  Let |n| be the [=list/size=] of |args|.
-        1.  Initialize |S| to the  [=effective overload set=]
-            for named constructors with [=identifier=] |id| on [=interface=] |I|
-            and with argument count |n|.
+        1.  [=Compute the effective overload set=] for named constructors with [=identifier=] |id|
+            on [=interface=] |I| and with argument count |n|, and let |S| be the result.
         1.  Let <|constructor|, |values|> be the result of passing |S| and
             |args| to the [=overload resolution algorithm=].
         1.  Let |object| be the result of [=internally create a new object implementing the
@@ -10739,9 +10736,8 @@ implement the interface on which the
         1.  Return |O|.
     1.  Let |F| be [=!=] CreateBuiltinFunction(|steps|, « », |realm|).
     1.  Perform [=!=] SetFunctionName(|F|, |id|).
-    1.  Initialize |S| to the [=effective overload set=]
-        for named constructors with identifier |id| on [=interface=] |I|
-        and with argument count 0.
+    1.  [=Compute the effective overload set=] for named constructors with [=identifier=] |id|
+        on [=interface=] |I| and with argument count 0, and let |S| be the result.
     1.  Let |length| be the length of the shortest argument list of the entries in |S|.
     1.  Perform [=!=] SetFunctionLength(|F|, |length|).
     1.  Let |proto| be the [=interface prototype object=] of [=interface=] |I| in |realm|.
@@ -11253,9 +11249,10 @@ in which case they are exposed on every object that [=implements=] the interface
                 1.  Set |idlObject| to the IDL [=interface type=] value that represents a reference
                     to |esValue|.
             1.  Let |n| be the [=list/size=] of |args|.
-            1.  Let |S| be the [=effective overload set=] for [=regular operations=] (if |op| is a
-                regular operation) or for [=static operations=] (if |op| is a static operation) with
-                [=identifier=] |id| on |target| and with argument count |n|.
+            1.  [=Compute the effective overload set=]  for [=regular operations=] (if |op| is a
+                regular operation) or for [=static operations=] (if |op| is a static operation)
+                with [=identifier=] |id| on |target| and with argument count |n|, and let |S| be
+                the result.
             1.  Let <|operation|, |values|> be the result of passing
                 |S| and |args| to the [=overload resolution algorithm=].
             1.  Let |R| be null.
@@ -11282,9 +11279,9 @@ in which case they are exposed on every object that [=implements=] the interface
         1.  Otherwise, end these steps and allow the exception to propagate.
     1.  Let |F| be [=!=] CreateBuiltinFunction(|steps|, « », |realm|).
     1.  Perform [=!=] SetFunctionName(|F|, |id|).
-    1.  Let |S| be the [=effective overload set=] for [=regular operations=] (if |op| is a regular
-        operation) or for [=static operations=] (if |op| is a static operation) with [=identifier=] |id|
-        on |target| and with argument count 0.
+    1.  [=Compute the effective overload set=]  for [=regular operations=] (if |op| is a regular
+        operation) or for [=static operations=] (if |op| is a static operation) with [=identifier=]
+        |id| on |target| and with argument count 0, and let |S| be the result.
     1.  Let |length| be the length of the shortest argument list in the entries in |S|.
     1.  Perform [=!=] SetFunctionLength(|F|, |length|).
     1.  Return |F|.