rust-lang / rust-lang/rust

`alloc::slice` docs have broken links

Open
#151,153 8 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-docs T-libs
Dominant language
Rust
Stars
119k
Forks
16.2k
PR merge metrics
PR metrics pending

Description

Location (URL)

https://doc.rust-lang.org/nightly/alloc/slice/index.html
https://doc.rust-lang.org/nightly/alloc/slice/trait.Concat.html
https://doc.rust-lang.org/nightly/alloc/slice/trait.Join.html

The problem also exists in stable docs.

Summary

The doc-comments for traits Concat and Join look like this:

/// Helper trait for [`[T]::concat`](slice::concat).
/// Helper trait for [`[T]::join`](slice::join)

This generates links to core/primitive.slice.html. But those don't methods don't exist in the core docs, so the link anchor doesn't work.

Those methods are only documented in std/primitive.slice.html: slice::concat and slice::join.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start from the alloc::slice documentation for the Concat and Join traits and inspect their doc-comments. Check the generated links against the std::primitive.slice documentation, then verify that both links resolve to the concat and join method anchors in the rendered docs.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
documentation
Issue type
Documentation
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
48/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.