docs(platform): drop restatement comments and fix broken rustdoc links#4583
Merged
Conversation
Remove three restatement comments that echo the adjacent code (Child:/ Parent: labels in the fork-based daemonize test, and a "Null terminator entry" label on a SERVICE_TABLE_ENTRYW with explicit null fields). Fix broken intra-doc links in the windows_service module documentation. The bracketed names resolved at module-doc time before the conditional pub use re-exports brought them into scope, breaking cargo doc on every target. Switch to backtick-only references for the local items and use a fully qualified path for SignalFlags. All SAFETY comments above unsafe blocks are preserved verbatim; this crate carries targeted #[allow(unsafe_code)] for platform FFI (chroot, daemonize, name resolution, privilege transitions).
3 tasks
This was referenced May 20, 2026
3 tasks
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
Per-crate comment cleanup pass on the
platformcrate. The crate was already in excellent shape (every public item documented, comprehensive SAFETY comments on every#[allow(unsafe_code)]block), so the cleanup is small.// Child:/// Parent:labels on the fork arms in thedaemonizetest (thepid == 0arm andchild_pidbinding self-document the branch), plus// Null terminator entry.on aSERVICE_TABLE_ENTRYWwhose fields are explicitnull_mut()/None.windows_service. Module-doc[\run_service_dispatcher`],[`ServiceStatusHandle`],[`install_service`],[`uninstall_service`], and[`signal::SignalFlags`]resolved before the#[cfg(windows)]/#[cfg(not(windows))]pub usere-exports brought the names into scope, socargo doc -p platform --no-depsfailed under#![deny(rustdoc::broken_intra_doc_links)]. Switched the four local items to backtick-only references and the cross-module link to a fully qualified[`crate::signal::SignalFlags`]` path, matching the known pitfall guidance.All SAFETY comments on
unsafeblocks were preserved verbatim. No new#[allow(...)]waivers. No semantic changes.Files touched: 2 (
crates/platform/src/daemonize.rs,crates/platform/src/windows_service.rs). Net: +5 / -8.Test plan
cargo fmt --all -- --checkclean.cargo clippy --workspace --all-targets --all-features --no-deps -- -D warningsclean.cargo doc -p platform --no-depsnow succeeds (previously failed with five broken intra-doc links).