Skip to content

should "variables can be used directly in the format! string" be a choice instead of a requirement? #98

@pwang200

Description

@pwang200

[Test / clippy_linting (pull_request)] fails many times because of issues like the one below.
Should println!("args: {:?}", args); style be allowed? My vote is yes.

error: variables can be used directly in the `format!` string
  --> src/commands/mod.rs:98:5
   |
98 |     println!("args: {:?}", args);
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args
help: change this to
   |
98 -     println!("args: {:?}", args);
98 +     println!("args: {args:?}");

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions