Skip to content

Commit

Permalink
Normative: Match ECMA‑262 order of the constructor property
Browse files Browse the repository at this point in the history
  • Loading branch information
ExE-Boss committed Oct 29, 2020
1 parent 67bc60f commit 7b3fafb
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -11374,6 +11374,9 @@ with the [{{LegacyNoInterfaceObject}}] [=extended attribute=].
to the definitions specified in
[=ECMA-262 Immutable prototype exotic objects=].
1. Otherwise, set |interfaceProtoObj| to [=!=] [$OrdinaryObjectCreate$](|proto|).
1. If the [{{LegacyNoInterfaceObject}}] [=extended attribute=] was not specified on |interface|, then:
1. Let |constructor| be the [=interface object=] of |interface| in |realm|.
1. Perform [=!=] [$CreateMethodProperty$](|interfaceProtoObj|, "<code>constructor</code>", |constructor|).
1. If |interface| has any [=member=] declared with the [{{Unscopable}}] [=extended attribute=],
then:

Expand All @@ -11397,12 +11400,6 @@ with the [{{LegacyNoInterfaceObject}}] [=extended attribute=].
1. [=Define the asynchronous iteration methods=] of |interface| on |interfaceProtoObj|
given |realm|.
1. [=Define the constants=] of |interface| on |interfaceProtoObj| given |realm|.
1. If the [{{LegacyNoInterfaceObject}}] [=extended attribute=] was not specified on |interface|, then:
1. Let |constructor| be the [=interface object=] of |interface| in |realm|.
1. Let |desc| be the PropertyDescriptor{\[[Writable]]: <emu-val>true</emu-val>,
\[[Enumerable]]: <emu-val>false</emu-val>, \[[Configurable]]: <emu-val>true</emu-val>,
\[[Value]]: |constructor|}.
1. Perform [=!=] <a abstract-op>DefinePropertyOrThrow</a>(|interfaceProtoObj|, "<code>constructor</code>", |desc|).
1. Return |interfaceProtoObj|.
</div>

Expand Down

0 comments on commit 7b3fafb

Please sign in to comment.