Skip to content

Add support for embedded-hal 1.0 #139

Add support for embedded-hal 1.0

Add support for embedded-hal 1.0 #139

GitHub Actions / clippy succeeded Jan 15, 2024 in 0s

clippy

4 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 4
Note 0
Help 0

Versions

  • rustc 1.75.0 (82e1608df 2023-12-21)
  • cargo 1.75.0 (1d8b05cdd 2023-11-20)
  • clippy 0.1.75 (82e1608 2023-12-21)

Annotations

Check warning on line 247 in src/time.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

call to `std::mem::drop` with a value that does not implement `Drop`. Dropping such a type only extends its contained lifetimes

warning: call to `std::mem::drop` with a value that does not implement `Drop`. Dropping such a type only extends its contained lifetimes
   --> src/time.rs:247:9
    |
247 |         drop(dwt);
    |         ^^^^^^^^^
    |
note: argument has type `gd32f1::gd32f130::DWT`
   --> src/time.rs:247:14
    |
247 |         drop(dwt);
    |              ^^^
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#drop_non_drop
    = note: `#[warn(clippy::drop_non_drop)]` on by default

Check warning on line 205 in src/flash.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting to the same type is unnecessary (`u32` -> `u32`)

warning: casting to the same type is unnecessary (`u32` -> `u32`)
   --> src/flash.rs:205:37
    |
205 |         if offset + length as u32 > self.flash_sz.kbytes() as u32 {
    |                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `self.flash_sz.kbytes()`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 174 in src/flash.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting to the same type is unnecessary (`u32` -> `u32`)

warning: casting to the same type is unnecessary (`u32` -> `u32`)
   --> src/flash.rs:174:56
    |
174 |                     let write_address = (FLASH_START + idx as u32) as *const u16;
    |                                                        ^^^^^^^^^^ help: try: `idx`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 117 in src/flash.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting to the same type is unnecessary (`u32` -> `u32`)

warning: casting to the same type is unnecessary (`u32` -> `u32`)
   --> src/flash.rs:117:37
    |
117 |         if offset + length as u32 > self.flash_sz.kbytes() as u32 {
    |                                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `self.flash_sz.kbytes()`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
    = note: `#[warn(clippy::unnecessary_cast)]` on by default