Skip to content

Commit 7c1caf9

Browse files
committed
Fix clippy::uninlined_format_args warning
``` error: variables can be used directly in the `format!` string --> examples/print.rs:29:17 | 29 | eprintln!("Received signal {:?}", signal); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#uninlined_format_args = note: `-D clippy::uninlined-format-args` implied by `-D warnings` = help: to override `-D warnings` add `#[allow(clippy::uninlined_format_args)]` help: change this to | 29 - eprintln!("Received signal {:?}", signal); 29 + eprintln!("Received signal {signal:?}"); | ```
1 parent 69004f5 commit 7c1caf9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

examples/print.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
2626
signals
2727
.for_each(|signal| {
2828
// Print the signal.
29-
eprintln!("Received signal {:?}", signal);
29+
eprintln!("Received signal {signal:?}");
3030

3131
// After printing it, do whatever the signal was supposed to do in the first place.
3232
low_level::emulate_default_handler(signal.unwrap() as i32).unwrap();

0 commit comments

Comments
 (0)