]> git.lizzy.rs Git - rust.git/blob - src/test/ui/fmt/feature-gate-format-args-capture.rs
Rollup merge of #73421 - janikrabe:master, r=joshtriplett
[rust.git] / src / test / ui / fmt / feature-gate-format-args-capture.rs
1 fn main() {
2     format!("{foo}");                //~ ERROR: there is no argument named `foo`
3
4     // panic! doesn't hit format_args! unless there are two or more arguments.
5     panic!("{foo} {bar}", bar=1);    //~ ERROR: there is no argument named `foo`
6 }