]> git.lizzy.rs Git - rust.git/commit
Auto merge of #7442 - camsteffen:format-args, r=xFrednet
authorbors <bors@rust-lang.org>
Tue, 13 Jul 2021 13:58:38 +0000 (13:58 +0000)
committerbors <bors@rust-lang.org>
Tue, 13 Jul 2021 13:58:38 +0000 (13:58 +0000)
commitbf4512ef57aaaebcf537af47380026d40238685b
tree80cbc9e7e0e242d8253cd00a9428aab0d6cce902
parent94d6be4c0a03d0149630bce7e6f373e327dd7471
parent306f9e843d5474eb2de6907b3ca6941dc918ea23
Auto merge of #7442 - camsteffen:format-args, r=xFrednet

Refactor `format_args!` expansion parsing

Introduces `FormatExpn::parse` and `FormatArgsExpn::parse`. Motivated by rust-lang/rust#83302, so I only have to change Clippy in one place. Fixed an FP along the way.

I also allowed `needless_bool` in macros because I often want to do `if_chain! { .. then { true } else { false } }`.

changelog: Fix false positive in `useless_format` when some text is appended or prepended to a single string with some useless formatting params
changelog: Allow `needless_bool` in macros