Skip to content

Make RenderOptions fields' type into newtype instead of boolean for clarity #87752

Open
@GuillaumeGomez

Description

@GuillaumeGomez

The discussion happened there: #84176 (comment). Quoting @estebank:

I meant newtyping the bools for each field, so that someone doesn't accidentally sets generate_link_to_definition to true, when they meant to set show_type_layout, although with named fields this is less of a concern.

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-cleanupCategory: PRs that clean code up or issues documenting cleanup.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