Skip to content

Commit

Permalink
Document that stream errors are final. (#84)
Browse files Browse the repository at this point in the history
  • Loading branch information
badeend authored Aug 7, 2024
1 parent 4adfff7 commit 38fe194
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions imports.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ when it does, they are expected to subsume this API.</p>
<p><a name="stream_error.last_operation_failed"></a><code>last-operation-failed</code>: own&lt;<a href="#error"><a href="#error"><code>error</code></a></a>&gt;</p>
<p>The last operation (a write or flush) failed before completion.
<p>More information is available in the <a href="#error"><code>error</code></a> payload.</p>
<p>After this, the stream will be closed. All future operations return
<a href="#stream_error.closed"><code>stream-error::closed</code></a>.</p>
</li>
<li>
<p><a name="stream_error.closed"></a><code>closed</code></p>
Expand Down
3 changes: 3 additions & 0 deletions wit/streams.wit
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ interface streams {
/// The last operation (a write or flush) failed before completion.
///
/// More information is available in the `error` payload.
///
/// After this, the stream will be closed. All future operations return
/// `stream-error::closed`.
last-operation-failed(error),
/// The stream is closed: no more input will be accepted by the
/// stream. A closed output-stream will return this error on all
Expand Down

0 comments on commit 38fe194

Please sign in to comment.