From 93b083f9db763d7e79b352912f14cec12d036db1 Mon Sep 17 00:00:00 2001 From: Brad Campbell Date: Sun, 10 Sep 2023 22:49:48 -0400 Subject: [PATCH] clippy: -D clippy::needless_lifetimes --- boards/nano_rp2040_connect/src/io.rs | 2 +- boards/pico_explorer_base/src/io.rs | 4 ++-- boards/raspberry_pi_pico/src/io.rs | 4 ++-- tools/run_clippy.sh | 1 - 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/boards/nano_rp2040_connect/src/io.rs b/boards/nano_rp2040_connect/src/io.rs index 1483058776..59236407fd 100644 --- a/boards/nano_rp2040_connect/src/io.rs +++ b/boards/nano_rp2040_connect/src/io.rs @@ -27,7 +27,7 @@ impl Writer { self.uart.set(uart); } - fn write_to_uart<'a>(&self, uart: &'a Uart, buf: &[u8]) { + fn write_to_uart(&self, uart: &Uart, buf: &[u8]) { for &c in buf { uart.send_byte(c); } diff --git a/boards/pico_explorer_base/src/io.rs b/boards/pico_explorer_base/src/io.rs index aba6fc7663..a327c973a8 100644 --- a/boards/pico_explorer_base/src/io.rs +++ b/boards/pico_explorer_base/src/io.rs @@ -27,7 +27,7 @@ impl Writer { self.uart.set(uart); } - fn configure_uart<'a>(&self, uart: &'a Uart) { + fn configure_uart(&self, uart: &Uart) { if !uart.is_configured() { let parameters = Parameters { baud_rate: 115200, @@ -46,7 +46,7 @@ impl Writer { } } - fn write_to_uart<'a>(&self, uart: &'a Uart, buf: &[u8]) { + fn write_to_uart(&self, uart: &Uart, buf: &[u8]) { for &c in buf { uart.send_byte(c); } diff --git a/boards/raspberry_pi_pico/src/io.rs b/boards/raspberry_pi_pico/src/io.rs index 1f5d6b433a..868779c0ab 100644 --- a/boards/raspberry_pi_pico/src/io.rs +++ b/boards/raspberry_pi_pico/src/io.rs @@ -27,7 +27,7 @@ impl Writer { self.uart.set(uart); } - fn configure_uart<'a>(&self, uart: &'a Uart) { + fn configure_uart(&self, uart: &Uart) { if !uart.is_configured() { let parameters = Parameters { baud_rate: 115200, @@ -46,7 +46,7 @@ impl Writer { } } - fn write_to_uart<'a>(&self, uart: &'a Uart, buf: &[u8]) { + fn write_to_uart(&self, uart: &Uart, buf: &[u8]) { for &c in buf { uart.send_byte(c); } diff --git a/tools/run_clippy.sh b/tools/run_clippy.sh index 4d680e03d1..53ba33406e 100755 --- a/tools/run_clippy.sh +++ b/tools/run_clippy.sh @@ -52,7 +52,6 @@ CLIPPY_ARGS_COMPLEXITY=" -A clippy::unnecessary_unwrap --A clippy::needless_lifetimes -A clippy::explicit_auto_deref -A clippy::explicit_counter_loop -A clippy::borrow_deref_ref