Repository navigation
docs(fast_io): drop restatement comments and apply rustdoc to public items - #4639
Merged
Merged
Conversation
…items - Remove restatement comments in status::platform_io_capabilities and syscall_batch tests that echo the code below them. - Tighten two comments in syscall_batch tests to describe routing intent and ordering invariant instead of restating the assertion. - Preserve every SAFETY block, upstream rsync citation, and meaningful WHY note across the crate. Excluded from this pass: `secure_dir.rs` and `lib.rs` (active in-flight work in #4618). The audit walked every other `.rs` file under `crates/fast_io/`; the bulk of the crate was already clean - SAFETY docs, kernel version gates, and platform quirks all preserved verbatim.
4 of 5 tasks
oferchen
added a commit
that referenced
this pull request
Aug 24, 2026
…items (#4639) - Remove restatement comments in status::platform_io_capabilities and syscall_batch tests that echo the code below them. - Tighten two comments in syscall_batch tests to describe routing intent and ordering invariant instead of restating the assertion. - Preserve every SAFETY block, upstream rsync citation, and meaningful WHY note across the crate. Excluded from this pass: `secure_dir.rs` and `lib.rs` (active in-flight work in #4618). The audit walked every other `.rs` file under `crates/fast_io/`; the bulk of the crate was already clean - SAFETY docs, kernel version gates, and platform quirks all preserved verbatim.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
.rsfile undercrates/fast_io/and removed restatement comments that echo the code below them.status.rs,syscall_batch.rs,splice/tests/linux/splice_to_file.rs.crates/fast_io/is clean: SAFETY blocks,#[allow(unsafe_code)]justifications, kernel version gates, Linux/Windows quirks,copy_file_rangefallback notes, and upstream rsync citations are all preserved verbatim.Scope
Touched:
crates/fast_io/src/status.rs- dropped three// <Platform> compile-time capabilitiescomments that restate the#[cfg(target_os = ...)]directly below them.crates/fast_io/src/syscall_batch.rs- dropped// Verify ...and// First should succeedrestatement comments in tests; tightened two// Below threshold - should use individual path/// Results should be in original order despite groupingnotes into single sentences describing intent.crates/fast_io/src/splice/tests/linux/splice_to_file.rs- dropped a// Verify file contents.restatement.Excluded from this pass (active in-flight work in #4618):
crates/fast_io/src/secure_dir.rscrates/fast_io/src/lib.rsDiff size
3 files changed, 9 insertions(+), 24 deletions(-).
Safety preservation
0 SAFETY blocks removed or modified. Every
// SAFETY:/// Safety:comment, every#[allow(unsafe_code)]justification, every kernel-version gate (5.6+ for io_uring, 5.19+ for splice multi-pipe, 3.11+ forO_TMPFILE), every Windows API quirk note (IOCP completion key reservation,CopyFileExcallback,ERROR_INSUFFICIENT_BUFFERhandling), everycopy_file_rangecross-filesystem fallback note, and every upstream rsync reference (io.c,syscall.c,socket.c,fileio.c,util1.c) is preserved verbatim.Test plan
cargo fmt --all -- --checkcargo clippy --workspace --all-targets --all-features --no-deps -- -D warningscargo check -p fast_io --all-featurescargo nextest run -p fast_io --features io_uring -E 'test(splice) or test(iocp_stub) or test(buffer_ring)'(16 passed)