Skip to content

Commit

Permalink
Normative: Guard IntegerIndexedElementSet with receiver check
Browse files Browse the repository at this point in the history
  • Loading branch information
shvaikalesh committed Mar 1, 2021
1 parent d9e5692 commit 8539513
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions spec.html
Original file line number Diff line number Diff line change
Expand Up @@ -11785,8 +11785,10 @@ <h1>[[Set]] ( _P_, _V_, _Receiver_ )</h1>
1. If Type(_P_) is String, then
1. Let _numericIndex_ be ! CanonicalNumericIndexString(_P_).
1. If _numericIndex_ is not *undefined*, then
1. Perform ? IntegerIndexedElementSet(_O_, _numericIndex_, _V_).
1. Return *true*.
1. If ! SameValue(_O_, _Receiver_) is *true*, then
1. Perform ? IntegerIndexedElementSet(_O_, _numericIndex_, _V_).
1. Return *true*.
1. If ! IsValidIntegerIndex(_O_, _numericIndex_) is *false*, return *true*.
1. Return ? OrdinarySet(_O_, _P_, _V_, _Receiver_).
</emu-alg>
</emu-clause>
Expand Down

0 comments on commit 8539513

Please sign in to comment.