Skip to content

Commit

Permalink
Rename [OverrideBuiltins] to [LegacyOverrideBuiltIns]
Browse files Browse the repository at this point in the history
Part of #350.
  • Loading branch information
domenic committed Apr 8, 2020
1 parent 2837492 commit fdb05ef
Showing 1 changed file with 18 additions and 18 deletions.
36 changes: 18 additions & 18 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1011,12 +1011,12 @@ The following extended attributes are applicable to interfaces:
[{{LegacyWindowAlias}}],
[{{NamedConstructor}}],
[{{NoInterfaceObject}}],
[{{OverrideBuiltins}}], and
[{{LegacyOverrideBuiltIns}}], and
[{{SecureContext}}].

The following extended attributes are applicable to [=partial interfaces=]:
[{{Exposed}}],
[{{OverrideBuiltins}}], and
[{{LegacyOverrideBuiltIns}}], and
[{{SecureContext}}].

[=Interfaces=] which are not annotated
Expand Down Expand Up @@ -9457,10 +9457,10 @@ used on an [=interface=], then:
* The interface must not define a [=named property setter=].
* The interface must not define [=indexed property getters=] or [=indexed property setter|setters=].
* The interface must not define a [=constructor operation=].
* The interface must not also be declared with the [{{OverrideBuiltins}}]
* The interface must not also be declared with the [{{LegacyOverrideBuiltIns}}]
extended attribute.
* The interface must not [=interface/inherit=] from another interface with the
[{{OverrideBuiltins}}] extended attribute.
[{{LegacyOverrideBuiltIns}}] extended attribute.
* Any other interface must not [=interface/inherit=] from it.

If [{{Global}}] is specified on
Expand Down Expand Up @@ -10159,29 +10159,29 @@ for the specific requirements that the use of
</div>


<h4 id="OverrideBuiltins" extended-attribute lt="OverrideBuiltins">[OverrideBuiltins]</h4>
<h4 id="LegacyOverrideBuiltIns" extended-attribute lt="LegacyOverrideBuiltIns" oldids="OverrideBuiltins">[LegacyOverrideBuiltIns]</h4>

<div class="advisement">

The [{{OverrideBuiltins}}] [=extended attribute=] is an undesirable feature.
The [{{LegacyOverrideBuiltIns}}] [=extended attribute=] is an undesirable feature.
It exists only so that legacy Web platform features can be specified.
It should not be used in specifications
unless required to specify the behavior of legacy APIs,
or for consistency with these APIs.
Editors who wish to use this feature are strongly advised to discuss this
by <a href="https://github.com/heycam/webidl/issues/new?title=Intent%20to%20use%20[OverrideBuiltins]">filing an issue</a>
by <a href="https://github.com/heycam/webidl/issues/new?title=Intent%20to%20use%20[LegacyOverrideBuiltIns]">filing an issue</a>
before proceeding.

<small class="non-normative">
The [{{OverrideBuiltins}}] [=extended attribute=] appears on the
The [{{LegacyOverrideBuiltIns}}] [=extended attribute=] appears on the
{{DOMStringMap}},
{{Document}}, and
{{HTMLFormElement}} [=interfaces=]. [[HTML]]
</small>

</div>

If the [{{OverrideBuiltins}}]
If the [{{LegacyOverrideBuiltIns}}]
[=extended attribute=]
appears on an [=interface=],
it indicates that for a [=legacy platform object=] implementing the interface,
Expand All @@ -10195,7 +10195,7 @@ This is in contrast to the usual behavior, which is for named properties
to be exposed only if there is no property with the
same name on the object itself or somewhere on its prototype chain.

The [{{OverrideBuiltins}}]
The [{{LegacyOverrideBuiltIns}}]
extended attribute must
[=takes no arguments|take no arguments=]
and must not appear on an interface
Expand All @@ -10207,14 +10207,14 @@ definition, then that partial interface definition must
be the part of the interface definition that defines
the [=named property getter=].

If the [{{OverrideBuiltins}}] extended attribute is specified on a
If the [{{LegacyOverrideBuiltIns}}] extended attribute is specified on a
[=partial interface=] definition, it is considered to appear on the
[=interface=] itself.

See [[#es-legacy-platform-objects]]
and [[#legacy-platform-object-defineownproperty]]
for the specific requirements that the use of
[{{OverrideBuiltins}}] entails.
[{{LegacyOverrideBuiltIns}}] entails.

<div class="example">

Expand All @@ -10231,7 +10231,7 @@ for the specific requirements that the use of
};

[Exposed=Window,
OverrideBuiltins]
LegacyOverrideBuiltIns]
interface StringMap2 {
readonly attribute unsigned long length;
getter DOMString lookup(DOMString key);
Expand Down Expand Up @@ -13436,7 +13436,7 @@ Additionally, [=legacy platform objects=] have internal methods as defined in:
and |P| is not an [=unforgeable property name=]
of |O|, then:
1. Let |creating| be true if |P| is not a [=supported property name=], and false otherwise.
1. If |O| [=implements=] an interface with the [{{OverrideBuiltins}}]
1. If |O| [=implements=] an interface with the [{{LegacyOverrideBuiltIns}}]
[=extended attribute=] or |O| does not have an own property
named |P|, then:
1. If |creating| is false and |O| does not implement an
Expand Down Expand Up @@ -13559,7 +13559,7 @@ internal method as follows.
The <dfn id="dfn-named-property-visibility" export>named property visibility algorithm</dfn>
is used to determine if a given named property is exposed on an object.
Some named properties are not exposed on an object depending on whether
the [{{OverrideBuiltins}}] [=extended attribute=] was used.
the [{{LegacyOverrideBuiltIns}}] [=extended attribute=] was used.
The algorithm operates as follows, with property name |P| and object |O|:

1. If |P| is not a [=supported property name=] of |O|, then return false.
Expand All @@ -13569,7 +13569,7 @@ internal method as follows.
because in practice those are always set up before objects have any supported property names,
and once set up will make the corresponding named properties invisible.

1. If |O| [=implements=] an interface that has the [{{OverrideBuiltins}}]
1. If |O| [=implements=] an interface that has the [{{LegacyOverrideBuiltIns}}]
[=extended attribute=], then return true.
1. Let |prototype| be |O|.\[[GetPrototypeOf]]().
1. While |prototype| is not null:
Expand All @@ -13585,10 +13585,10 @@ internal method as follows.

1. Indexed properties.
1. Own properties, including unforgeable attributes and operations.
1. Then, if [{{OverrideBuiltins}}]:
1. Then, if [{{LegacyOverrideBuiltIns}}]:
1. Named properties.
1. Properties from the prototype chain.
1. Otherwise, if not [{{OverrideBuiltins}}]:
1. Otherwise, if not [{{LegacyOverrideBuiltIns}}]:
1. Properties from the prototype chain.
1. Named properties.
</div>
Expand Down

0 comments on commit fdb05ef

Please sign in to comment.