]> git.lizzy.rs Git - rust.git/blob - tests/ui/fmt/format-args-capture-issue-102057.rs
Rollup merge of #106321 - compiler-errors:delayed-bug-backtrace, r=Nilstrieb
[rust.git] / tests / ui / fmt / format-args-capture-issue-102057.rs
1 fn main() {
2     format!("\x7Ba}");
3     //~^ ERROR cannot find value `a` in this scope
4     format!("\x7Ba\x7D");
5     //~^ ERROR cannot find value `a` in this scope
6
7     let a = 0;
8
9     format!("\x7Ba} {b}");
10     //~^ ERROR cannot find value `b` in this scope
11     format!("\x7Ba\x7D {b}");
12     //~^ ERROR cannot find value `b` in this scope
13     format!("\x7Ba} \x7Bb}");
14     //~^ ERROR cannot find value `b` in this scope
15     format!("\x7Ba\x7D \x7Bb}");
16     //~^ ERROR cannot find value `b` in this scope
17     format!("\x7Ba\x7D \x7Bb\x7D");
18     //~^ ERROR cannot find value `b` in this scope
19 }