Closed
Description
fn main() {
format!("{:x}", a=1);
}
warning: named argument `a` is not used by name
--> src/main.rs:2:21
|
2 | format!("{:x}", a=1);
| ---- ^ this named argument is referred to by position in formatting string
| |
| this formatting argument uses named argument `a` by position
|
= note: `#[warn(named_arguments_used_positionally)]` on by default
help: use the named argument by name to avoid ambiguity
|
2 | format!("{a}", a=1);
| ~
The :x
disappears.