Browse Source

Fix clippy lints

Signed-off-by: Daniel Egger <daniel@eggers-club.de>
trying.tmp
Daniel Egger 3 years ago
parent
commit
91bb5d8418
  1. 6
      src/gpio.rs
  2. 2
      src/spi.rs
  3. 1
      src/timers.rs

6
src/gpio.rs

@ -103,12 +103,14 @@ impl<MODE> OutputPin for Pin<Output<MODE>> {
#[inline(always)]
fn set_high(&mut self) -> Result<(), Self::Error> {
Ok(unsafe { (*self.port).set_high(self.i) })
unsafe { (*self.port).set_high(self.i) };
Ok(())
}
#[inline(always)]
fn set_low(&mut self) -> Result<(), Self::Error> {
Ok(unsafe { (*self.port).set_low(self.i) })
unsafe { (*self.port).set_low(self.i) }
Ok(())
}
}

2
src/spi.rs

@ -40,8 +40,6 @@
use core::marker::PhantomData;
use core::{ops::Deref, ptr};
use nb;
pub use embedded_hal::spi::{Mode, Phase, Polarity};
// TODO Put this inside the macro

1
src/timers.rs

@ -35,7 +35,6 @@ use crate::rcc::{Clocks, Rcc};
use crate::time::Hertz;
use embedded_hal::timer::{CountDown, Periodic};
use nb;
use void::Void;
/// Hardware timers

Loading…
Cancel
Save