Skip to content

Incorrect signature in documentation for implementation of generic alias #111420

Closed
@drewcassidy

Description

@drewcassidy

I tried this code:

// Cross Product
impl<T: Copy> Vector<T, 3> {
   // ✂️ snip ✂️ 
}

where Vector is

pub type Vector<T, const N: usize> = Matrix<T, N, 1>;

In the cargo doc output, this shows impl<T: Copy> Matrix<T, N, 1> even though N no longer exists in this context, its been concretized to 3
image

If I change the implementation to use Matrix instead of the Vector alias, I see what I would expect. no more N

image

Project is here, with the specific impl here

Meta

rustc --version --verbose:

rustc 1.69.0 (84c898d65 2023-04-16)
binary: rustc
commit-hash: 84c898d65adf2f39a5a98507f1fe0ce10a2b8dbc
commit-date: 2023-04-16
host: aarch64-apple-darwin
release: 1.69.0
LLVM version: 15.0.7

Backtrace

I don't seem to get anything and I don't know why

Metadata

Metadata

Labels

C-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