Skip to content

rustdoc emits spurious build errors due to unsatisfied trait bounds on code that compiles fine #117796

Open
@AlexTMjugador

Description

@AlexTMjugador

I tried this code: zopfli-rs/zopfli#36

I expected to see this happen: the CI build workflow completes fine.

Instead, this happened: the CI build workflow run failed to build the crate documentation. However, the crate compiles without any problems when using cargo test and cargo build with the same features:

Error screenshot

I suspect there's a new issue with the latest nightly rustdoc, leading to unexpected trait bound errors. This suspicion stems from the fact that the same command works well under rustc 1.75.0-nightly (df871fbf0 2023-10-24). Additionally, there have been recent changes made to the code that rustdoc accepts: #117622, #117450

Meta

rustc --version --verbose:

rustc 1.75.0-nightly (0f44eb32f 2023-11-09)
binary: rustc
commit-hash: 0f44eb32f1123ac93ab404d74c295263ce468343
commit-date: 2023-11-09
host: x86_64-unknown-linux-gnu
release: 1.75.0-nightly
LLVM version: 17.0.4

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions