Skip to content

rustdoc: confusing use of "type" #75623

Closed
@RalfJung

Description

@RalfJung

The rustdoc help says

Prefix searches with a type followed by a colon (e.g., fn:) to restrict the search to a given type.

Accepted types are: fn, mod, struct, enum, trait, type, macro, and const.

However, in Rust lingo, struct or enum isn't a "type". Vec<i32> is a type. And macro, trait and const certainly aren't "types".

IMO this should at least be qualified to something like "item type", but I think "item kind" would be even better.

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsA-type-based-searchArea: Searching rustdoc pages using type signaturesT-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