Skip to content

intra-rustdoc links fail on primitive methods #58598

Closed
@tspiteri

Description

@tspiteri

I hit this in #58596.

For example, for this a.rs

//! [`Vec`] is fine.
//! [`Vec::len`] is fine.
//! [`char`] is fine.
//! [`char::len_utf8`] is not.

rustdoc +nightly a.rs produces

 --> a.rs:4:6
  |
4 | //! [`char::len_utf8`] is not.
  |      ^^^^^^^^^^^^^^^^ cannot be resolved, ignoring
  |
  = note: #[warn(intra_doc_link_resolution_failure)] on by default
  = help: to escape `[` and `]` characters, just add '\' before them like `\[` or `\]`

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-intra-doc-linksArea: Intra-doc links, the ability to link to items in docs by nameC-bugCategory: This is a bug.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