Skip to content

Commit f70a19f

Browse files
authored
Change timeout from f64 ms -> i64 ns (WebAssembly#43)
See issue WebAssembly#36.
1 parent 59adc4a commit f70a19f

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

proposals/threads/Overview.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -350,15 +350,13 @@ woken by [`Atomics.wake`][].
350350
### Wait
351351

352352
The wait operator take three operands: an address operand, an expected value,
353-
and a relative timeout in milliseconds as an `f64`. The return value is `0`,
353+
and a relative timeout in nanoseconds as an `i64`. The return value is `0`,
354354
`1`, or `2`, returned as an `i32`.
355355

356356
| `timeout` value | Behavior |
357357
| ---- | ---- |
358-
| `timeout` <= 0 | Expires immediately |
359-
| 0 < `timeout` < Positive infinity | Expires after `timeout` milliseconds |
360-
| Positive infinity | Never expires |
361-
| NaN | Never expires |
358+
| `timeout` < 0 | Never expires |
359+
| 0 <= `timeout` <= maximum signed i64 value | Expires after `timeout` nanoseconds |
362360

363361
| Return value | Description |
364362
| ---- | ---- |

0 commit comments

Comments
 (0)