Skip to content

std::fmt documentation does not explain the colon #131865

Closed
@kpreid

Description

@kpreid

Location

https://doc.rust-lang.org/std/fmt/

Summary

The documentation of format strings uses the colon “:” without ever explaining what its role is. To some it will be obvious, but others will benefit from a brief explanation of the general syntax principle: that everything to the left of the “:” is the identifier of the input data, everything to the right is formatting options, and the colon per se does not change anything at all but only introduces the options.

@rustbot label +A-fmt

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsA-fmtArea: `core::fmt`T-libsRelevant to the library 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