os-rust/tests/ui/macros/format-empty-block-unit-tuple-suggestion-130170.fixed

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

14 lines
431 B
Rust
Raw Permalink Normal View History

//@ run-rustfix
fn main() {
let s = "123";
println!("{:?} {} {}", {}, "sss", s);
//~^ ERROR format argument must be a string literal
println!("{:?}", {});
//~^ ERROR format argument must be a string literal
println!("{} {} {} {:?}", s, "sss", s, {});
//~^ ERROR format argument must be a string literal
println!("{:?} {} {:?}", (), s, {});
//~^ ERROR format argument must be a string literal
}