diff options
| author | Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> | 2024-11-26 22:46:12 +0100 |
|---|---|---|
| committer | Piotr Osiewicz <24362066+osiewicz@users.noreply.github.com> | 2024-11-26 22:46:12 +0100 |
| commit | f4ab9829e1a3c6e564f79c98f39632aecbc675d3 (patch) | |
| tree | 46fe26e479aa1b98a120bb3de276f58e8335494e | |
| parent | 692c19ae8032f80fc75912b98651bfc841cfbaf0 (diff) | |
| download | rust-f4ab9829e1a3c6e564f79c98f39632aecbc675d3.tar.gz rust-f4ab9829e1a3c6e564f79c98f39632aecbc675d3.zip | |
chore: Improve doc comments
| -rw-r--r-- | library/std/src/sys/pal/wasi/fs.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/library/std/src/sys/pal/wasi/fs.rs b/library/std/src/sys/pal/wasi/fs.rs index 5c6ddfa559e..9e233436a84 100644 --- a/library/std/src/sys/pal/wasi/fs.rs +++ b/library/std/src/sys/pal/wasi/fs.rs @@ -31,7 +31,7 @@ pub struct ReadDir { } enum ReadDirState { - /// Next DirEntry should be read from contents of buf at `offset` + /// Fill `buf` with `buf.len()` bytes starting from `next_read_offset`. FillBuffer { next_read_offset: wasi::Dircookie, buf: Vec<u8>, @@ -41,7 +41,8 @@ enum ReadDirState { next_read_offset: Option<wasi::Dircookie>, offset: usize, }, - /// Do not fetch any more entries, process all entries + /// There is no more data to get in [`Self::FillBuffer`]; keep returning + /// entries via ProcessEntry until `buf` is exhausted. RunUntilExhaustion { buf: Vec<u8>, offset: usize, |
