Skip to content

Documentation text on trait impl methods is hidden in docs #24838

Closed
@bluss

Description

@bluss

I use documentation on my trait impls to tell users about how my types behave:

impl<N, E, Ty, Ix> Index<NodeIndex<Ix>> for Graph<N, E, Ty, Ix> where
    Ty: EdgeType,
    Ix: IndexType,
{
    type Output = N;
    /// Index the **Graph** by **NodeIndex** to access node weights.
    ///
    /// **Panics** if the node doesn't exist.
    fn index(&self, index: NodeIndex<Ix>) -> &N {
        &self.nodes[index.index()].weight
    }
}

This documentation is not rendered anymore. I expect to see it under the entry for the Index implementation of the Graph type.

I think this was lost after (the otherwise very awesome!) documentation changes by @alexcrichton

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