Skip to content

Commit 6bb5146

Browse files
Update to v0.2.7 (#90)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
1 parent 77ceead commit 6bb5146

File tree

10 files changed

+28
-60
lines changed

10 files changed

+28
-60
lines changed

imports.md

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,14 +2,14 @@
22
<ul>
33
<li>Imports:
44
<ul>
5-
<li>interface <a href="#wasi_io_poll_0_2_6"><code>wasi:io/[email protected].6</code></a></li>
6-
<li>interface <a href="#wasi_clocks_monotonic_clock_0_2_6"><code>wasi:clocks/[email protected].6</code></a></li>
7-
<li>interface <a href="#wasi_clocks_wall_clock_0_2_6"><code>wasi:clocks/[email protected].6</code></a></li>
8-
<li>interface <a href="#wasi_clocks_timezone_0_2_6"><code>wasi:clocks/[email protected].6</code></a></li>
5+
<li>interface <a href="#wasi_io_poll_0_2_7"><code>wasi:io/[email protected].7</code></a></li>
6+
<li>interface <a href="#wasi_clocks_monotonic_clock_0_2_7"><code>wasi:clocks/[email protected].7</code></a></li>
7+
<li>interface <a href="#wasi_clocks_wall_clock_0_2_7"><code>wasi:clocks/[email protected].7</code></a></li>
8+
<li>interface <a href="#wasi_clocks_timezone_0_2_7"><code>wasi:clocks/[email protected].7</code></a></li>
99
</ul>
1010
</li>
1111
</ul>
12-
<h2><a id="wasi_io_poll_0_2_6"></a>Import interface wasi:io/[email protected].6</h2>
12+
<h2><a id="wasi_io_poll_0_2_7"></a>Import interface wasi:io/[email protected].7</h2>
1313
<p>A poll API intended to let users wait for I/O events on multiple handles
1414
at once.</p>
1515
<hr />
@@ -62,7 +62,7 @@ being ready for I/O.</p>
6262
<ul>
6363
<li><a id="poll.0"></a> list&lt;<code>u32</code>&gt;</li>
6464
</ul>
65-
<h2><a id="wasi_clocks_monotonic_clock_0_2_6"></a>Import interface wasi:clocks/[email protected].6</h2>
65+
<h2><a id="wasi_clocks_monotonic_clock_0_2_7"></a>Import interface wasi:clocks/[email protected].7</h2>
6666
<p>WASI Monotonic Clock is a clock API intended to let users measure elapsed
6767
time.</p>
6868
<p>It is intended to be portable at least between Unix-family platforms and
@@ -121,7 +121,7 @@ elapsed from the time this function is invoked.</p>
121121
<ul>
122122
<li><a id="subscribe_duration.0"></a> own&lt;<a href="#pollable"><a href="#pollable"><code>pollable</code></a></a>&gt;</li>
123123
</ul>
124-
<h2><a id="wasi_clocks_wall_clock_0_2_6"></a>Import interface wasi:clocks/[email protected].6</h2>
124+
<h2><a id="wasi_clocks_wall_clock_0_2_7"></a>Import interface wasi:clocks/[email protected].7</h2>
125125
<p>WASI Wall Clock is a clock API intended to let users query the current
126126
time. The name &quot;wall&quot; makes an analogy to a &quot;clock on the wall&quot;, which
127127
is not necessarily monotonic as it may be reset.</p>
@@ -162,7 +162,7 @@ also known as <a href="https://en.wikipedia.org/wiki/Unix_time">Unix Time</a>.</
162162
<ul>
163163
<li><a id="resolution.0"></a> <a href="#datetime"><a href="#datetime"><code>datetime</code></a></a></li>
164164
</ul>
165-
<h2><a id="wasi_clocks_timezone_0_2_6"></a>Import interface wasi:clocks/[email protected].6</h2>
165+
<h2><a id="wasi_clocks_timezone_0_2_7"></a>Import interface wasi:clocks/[email protected].7</h2>
166166
<hr />
167167
<h3>Types</h3>
168168
<h4><a id="datetime"></a><code>type datetime</code></h4>

wit/deps.lock

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[io]
22
url = "https://github.com/WebAssembly/wasi-io/archive/main.tar.gz"
3-
sha256 = "671761f464d312e6c26bcaab5e79fe14ac876b72267867579d5c65e053fe2301"
4-
sha512 = "57e5ed34fa85f35899b324ac7a2473c5fa5cece51d07e6f077637191fadd3c8b6f79324d31a8d497a6ce7b92cfb2a2505ab894337e2c82889f1bdb21f4f24634"
3+
sha256 = "62ae80f2e340cddbac8e94f78e6270735aea536367ecb98de5f4ac6aef66b5c4"
4+
sha512 = "a02a1ebd261ae884b0315b3528d1a93819ddc4b616f66c77f2bea9dd1de888208dc3b9004a553363f5e8491ea925d65ebbd0d68eaa87238316b47469a3bf97bb"

wit/deps/io/error.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:io@0.2.6;
1+
package wasi:io@0.2.7;
22

33
@since(version = 0.2.0)
44
interface error {

wit/deps/io/poll.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:io@0.2.6;
1+
package wasi:io@0.2.7;
22

33
/// A poll API intended to let users wait for I/O events on multiple handles
44
/// at once.

wit/deps/io/streams.wit

Lines changed: 10 additions & 42 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:io@0.2.6;
1+
package wasi:io@0.2.7;
22

33
/// WASI I/O is an I/O abstraction API which is currently focused on providing
44
/// stream types.
@@ -154,27 +154,13 @@ interface streams {
154154
/// Perform a write of up to 4096 bytes, and then flush the stream. Block
155155
/// until all of these operations are complete, or an error occurs.
156156
///
157-
/// This is a convenience wrapper around the use of `check-write`,
158-
/// `subscribe`, `write`, and `flush`, and is implemented with the
159-
/// following pseudo-code:
160-
///
161-
/// ```text
162-
/// let pollable = this.subscribe();
163-
/// while !contents.is_empty() {
164-
/// // Wait for the stream to become writable
165-
/// pollable.block();
166-
/// let Ok(n) = this.check-write(); // eliding error handling
167-
/// let len = min(n, contents.len());
168-
/// let (chunk, rest) = contents.split_at(len);
169-
/// this.write(chunk ); // eliding error handling
170-
/// contents = rest;
171-
/// }
172-
/// this.flush();
173-
/// // Wait for completion of `flush`
174-
/// pollable.block();
175-
/// // Check for any errors that arose during `flush`
176-
/// let _ = this.check-write(); // eliding error handling
177-
/// ```
157+
/// Returns success when all of the contents written are successfully
158+
/// flushed to output. If an error occurs at any point before all
159+
/// contents are successfully flushed, that error is returned as soon as
160+
/// possible. If writing and flushing the complete contents causes the
161+
/// stream to become closed, this call should return success, and
162+
/// subsequent calls to check-write or other interfaces should return
163+
/// stream-error::closed.
178164
@since(version = 0.2.0)
179165
blocking-write-and-flush: func(
180166
contents: list<u8>
@@ -227,26 +213,8 @@ interface streams {
227213
/// Block until all of these operations are complete, or an error
228214
/// occurs.
229215
///
230-
/// This is a convenience wrapper around the use of `check-write`,
231-
/// `subscribe`, `write-zeroes`, and `flush`, and is implemented with
232-
/// the following pseudo-code:
233-
///
234-
/// ```text
235-
/// let pollable = this.subscribe();
236-
/// while num_zeroes != 0 {
237-
/// // Wait for the stream to become writable
238-
/// pollable.block();
239-
/// let Ok(n) = this.check-write(); // eliding error handling
240-
/// let len = min(n, num_zeroes);
241-
/// this.write-zeroes(len); // eliding error handling
242-
/// num_zeroes -= len;
243-
/// }
244-
/// this.flush();
245-
/// // Wait for completion of `flush`
246-
/// pollable.block();
247-
/// // Check for any errors that arose during `flush`
248-
/// let _ = this.check-write(); // eliding error handling
249-
/// ```
216+
/// Functionality is equivelant to `blocking-write-and-flush` with
217+
/// contents given as a list of len containing only zeroes.
250218
@since(version = 0.2.0)
251219
blocking-write-zeroes-and-flush: func(
252220
/// The number of zero-bytes to write

wit/deps/io/world.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:io@0.2.6;
1+
package wasi:io@0.2.7;
22

33
@since(version = 0.2.0)
44
world imports {

wit/monotonic-clock.wit

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:clocks@0.2.6;
1+
package wasi:clocks@0.2.7;
22
/// WASI Monotonic Clock is a clock API intended to let users measure elapsed
33
/// time.
44
///
@@ -10,7 +10,7 @@ package wasi:[email protected];
1010
@since(version = 0.2.0)
1111
interface monotonic-clock {
1212
@since(version = 0.2.0)
13-
use wasi:io/poll@0.2.6.{pollable};
13+
use wasi:io/poll@0.2.7.{pollable};
1414

1515
/// An instant in time, in nanoseconds. An instant is relative to an
1616
/// unspecified initial value, and can only be compared to instances from

wit/timezone.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:clocks@0.2.6;
1+
package wasi:clocks@0.2.7;
22

33
@unstable(feature = clocks-timezone)
44
interface timezone {

wit/wall-clock.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:clocks@0.2.6;
1+
package wasi:clocks@0.2.7;
22
/// WASI Wall Clock is a clock API intended to let users query the current
33
/// time. The name "wall" makes an analogy to a "clock on the wall", which
44
/// is not necessarily monotonic as it may be reset.

wit/world.wit

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
package wasi:clocks@0.2.6;
1+
package wasi:clocks@0.2.7;
22

33
@since(version = 0.2.0)
44
world imports {

0 commit comments

Comments
 (0)