From e6395eaf9d82358c22d6c131604c2a50dabe019d Mon Sep 17 00:00:00 2001 From: Astro Date: Sat, 27 Apr 2019 15:25:27 +0200 Subject: [PATCH] clippy delint --- src/main.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main.rs b/src/main.rs index 511a65e..5d6c39c 100644 --- a/src/main.rs +++ b/src/main.rs @@ -123,7 +123,7 @@ fn main() -> ! { let mut last_output = 0_u32; loop { let now = timer::now().0; - let instant = Instant::from_millis(now as i64); + let instant = Instant::from_millis(i64::from(now)); led_blue.on(); cortex_m::interrupt::free(net::clear_pending); server.poll(instant) @@ -136,7 +136,7 @@ fn main() -> ! { if now - last_output >= OUTPUT_INTERVAL { led_red.on(); let adc_value = adc_input.read(); - write!(server, "t={},pa3={}\r\n", now, adc_value).unwrap(); + writeln!(server, "t={},pa3={}\r", now, adc_value).unwrap(); last_output = now; led_red.off(); }