Skip to content

refactor: simplify docsrs cfg#105

Open
Frando wants to merge 1 commit into
mainfrom
Frando/docsrs-cfg
Open

refactor: simplify docsrs cfg#105
Frando wants to merge 1 commit into
mainfrom
Frando/docsrs-cfg

Conversation

@Frando

@Frando Frando commented Jun 16, 2026

Copy link
Copy Markdown
Member

Cleans up the feature-gate doc machinery left over from the quic-rpc origins.

  • Drop the per-item doc(cfg(...)) annotations. Rustdoc now infers feature badges from the real #[cfg(...)] gates automatically. doc_auto_cfg was merged into doc_cfg in Rust 1.92 (rust-lang/rust#138907), so it is the default when feature(doc_cfg) is on. feature(doc_cfg) is nightly-only, but it is gated behind the irpc_docsrs cfg that only docs.rs sets. Regular builds never see it, so our MSRV stays at 1.91 on stable.
  • Rename quicrpc_docsrs to irpc_docsrs, matching the crate name and the iroh_docsrs convention.

We keep a crate-specific cfg rather than the common docsrs because --cfg docsrs leaks into dependencies. A full doc build fails when cordyceps enables now-removed features behind #[cfg(docsrs)]. Using irpc_docsrs sidesteps that.

@Frando Frando requested a review from rklaehn June 16, 2026 12:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant