Skip to content

Commit

Permalink
Use the intended variable in 'run a host function'.
Browse files Browse the repository at this point in the history
This also fixes nearby cross-references.

Fixes WebAssembly#24.
  • Loading branch information
Ms2ger committed Sep 30, 2019
1 parent 22d3e26 commit 9b9bb64
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions document/js-api/index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1007,10 +1007,10 @@ Note: Exported Functions do not have a \[[Construct]] method and thus it is not
1. For each |arg| in |arguments|,
1. [=list/Append=] ! [=ToJSValue=](|arg|) to |jsArguments|.
1. Let |ret| be ? [=Call=](|func|, undefined, |jsArguments|).
1. If |results| [=list/empty=], return undefined.
1. If |results| [=list/is empty=], return undefined.
1. Otherwise, if |results|'s [=list/size=] is 1, return ? [=ToWebAssemblyValue=](|ret|, |results|[0]).
1. Otherwise,
1. Let |method| be ? [=GetMethod=](|results|, @@iterator).
1. Let |method| be ? [=GetMethod=](|ret|, [=@@iterator=]).
1. If |method| is undefined, [=throw=] a {{TypeError}}.
1. Let |values| be ? [=IterableToList=](|ret|, |method|).
1. Let |wasmValues| be a new, empty [=list=].
Expand Down

0 comments on commit 9b9bb64

Please sign in to comment.