Skip to content

rustdoc: redundant_explicit_links does not fire when link target is url segment. #155458

@lolbinarycat

Description

@lolbinarycat

Code

#![deny(rustdoc::redundant_explicit_links)]

/// [B](struct.B.html)
pub struct A;

pub struct B;

Reproduction Steps

run rustdoc on the above file.

Expected Outcome

rustdoc::redundant_explicit_links is emitted.

Actual Outcome

No output, successful compilation

Version

rustdoc 1.94.0 (4a4ef49 2026-03-02)

Additional Details

Unsure if this is intentional, a technical limitation, or just a simple bug, but it is strange.

Metadata

Metadata

Assignees

Labels

C-bugCategory: This is a bug.T-rustdocRelevant to the rustdoc team, which will review and decide on the PR/issue.needs-triageThis issue may need triage. Remove it if it has been sufficiently triaged.

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions