Skip to content

Commit

Permalink
Add index to mapper
Browse files Browse the repository at this point in the history
  • Loading branch information
domfarolino committed Feb 8, 2024
1 parent b386eb5 commit cb80f57
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion spec.bs
Original file line number Diff line number Diff line change
Expand Up @@ -666,16 +666,20 @@ For now, see [https://github.com/wicg/observable#operators](https://github.com/w

1. Let |controller| be a [=new=] {{AbortController}}.

1. Let |idx| be an {{unsigned long long}}, initially 0.

1. Let |sourceObserver| be a new [=internal observer=], initialized as follows:

: [=internal observer/next steps=]
:: 1. [=Invoke=] |mapper| with the passed in <var ignore>value</var>, and let
:: 1. [=Invoke=] |mapper| with the passed in <var ignore>value</var>, and |idx|, and let
|mappedValue| be the returned value.

If <a spec=webidl lt="an exception was thrown">an exception |E| was thrown</a>,
then run |subscriber|'s {{Subscriber/error()}} method, given |E|,
[=AbortController/signal abort=] |controller|, and abort these steps.

1. Increment |idx|.

1. Run |subscriber|'s {{Subscriber/next()}} method, given |mappedValue|.

: [=internal observer/error steps=]
Expand Down

0 comments on commit cb80f57

Please sign in to comment.