Skip to content

Commit

Permalink
Revert "Normative: Remove class decorator access to private names" (#197
Browse files Browse the repository at this point in the history
)

This reverts PR #151.

Rationale in #133 (comment)
  • Loading branch information
littledan authored Jan 9, 2019
1 parent 1347bc2 commit 078f491
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -750,17 +750,15 @@ <h1>DecorateConstructor ( _elements_, _decorators_ )</h1>
<emu-alg>
1. Let _finishers_ be a new empty List.
1. For each _decorator_ in _decorators_, in reverse list order do
1. Let _privateElements_ be a List consisting of the ordered subsequence of _elements_ for each _element_ where _element_.[[Key]] is a Private Name.
1. Let _publicElements_ be a List consisting of the ordered subsequence of _elements_ for each _element_ where _element_.[[Key]] is not a Private Name.
1. Let _obj_ be FromClassDescriptor(_publicElements_).
1. Let _obj_ be FromClassDescriptor(_elements_).
1. Let _result_ be ? Call(_decorator_, *undefined*, « _obj_ »).
1. If _result_ is *undefined*, let _result_ be _obj_.
1. Otherwise, set _result_ to ? ToObject(_result_).
1. Let _elementsAndFinisher_ be ? ToClassDescriptor(_result_).
1. If _elementsAndFinisher_.[[Finisher]] is not *undefined*,
1. Append _elementsAndFinisher_.[[Finisher]] to _finishers_.
1. If _elementsAndFinisher_.[[Elements]] is not *undefined*,
1. Set _elements_ to the concatenation of _elementsAndFinisher_.[[Elements]] and _privateElements_.
1. Set _elements_ to _elementsAndFinisher_.[[Elements]].
1. If there are two class elements _a_ and _b_ in _elements_ such that all of the following are true:
1. _a_.[[Kind]] is not `"initializer"`
1. _b_.[[Kind]] is not `"initializer"`
Expand Down

0 comments on commit 078f491

Please sign in to comment.