-
Notifications
You must be signed in to change notification settings - Fork 13.6k
Closed
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and toolsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.
Description
Location
Summary
The docs for write_fmt
in Formatter do not line up with the docs for write_fmt
in the Write trait. The write trait warns you that you should be using the write!
macro, but the method in Formatter
doesn't. If you are implementing core::fmt::Debug
and call write_fmt
on the provided Formatter
object directly, and use the wrong arguments, the rust-analyzer error will use Formatter
docs, which will mislead the user into simply wrapping the arguments via format_args!
instead of using a write!
macro.
Metadata
Metadata
Assignees
Labels
A-docsArea: Documentation for any part of the project, including the compiler, standard library, and toolsArea: Documentation for any part of the project, including the compiler, standard library, and toolsT-libsRelevant to the library team, which will review and decide on the PR/issue.Relevant to the library team, which will review and decide on the PR/issue.