diff options
| author | Eli Hastings <eli@seagen.io> | 2025-03-24 09:38:05 +0000 |
|---|---|---|
| committer | Henrik Tjäder <henrik@tjaders.com> | 2025-04-07 21:11:21 +0000 |
| commit | 104ee94dd1d0944ddcb29ac7c8b1634a659cb727 (patch) | |
| tree | 940d3bb497cf95ae54546d51fd13510dc7cfb410 | |
| parent | 0615841cb8fe3c4aa65c79d05d5183298a12a39e (diff) | |
Apply clippy fixes
| -rw-r--r-- | rtic-macros/src/codegen/bindings/esp32c6.rs | 5 | ||||
| -rw-r--r-- | rtic/src/export/riscv_esp32c6.rs | 3 |
2 files changed, 4 insertions, 4 deletions
diff --git a/rtic-macros/src/codegen/bindings/esp32c6.rs b/rtic-macros/src/codegen/bindings/esp32c6.rs index 1d22466..263651b 100644 --- a/rtic-macros/src/codegen/bindings/esp32c6.rs +++ b/rtic-macros/src/codegen/bindings/esp32c6.rs @@ -2,6 +2,7 @@ pub use esp32c6::*; #[cfg(feature = "riscv-esp32c6")] +#[allow(clippy::module_inception)] mod esp32c6 { use crate::{ analyze::Analysis as CodegenAnalysis, @@ -97,7 +98,7 @@ mod esp32c6 { .chain( app.hardware_tasks .values() - .filter_map(|task| Some((&task.args.priority, &task.args.binds))), + .map(|task| (&task.args.priority, &task.args.binds)), ) .zip(EXTERNAL_INTERRUPTS) { @@ -238,7 +239,7 @@ mod esp32c6 { .chain( app.hardware_tasks .values() - .filter_map(|task| Some((&task.args.priority, &task.args.binds))), + .map(|task| (&task.args.priority, &task.args.binds)), ) .zip(EXTERNAL_INTERRUPTS) { diff --git a/rtic/src/export/riscv_esp32c6.rs b/rtic/src/export/riscv_esp32c6.rs index 6789f26..7bd5303 100644 --- a/rtic/src/export/riscv_esp32c6.rs +++ b/rtic/src/export/riscv_esp32c6.rs @@ -58,8 +58,7 @@ where pub unsafe fn lock<T, R>(ptr: *mut T, ceiling: u8, f: impl FnOnce(&mut T) -> R) -> R { if ceiling == (15) { // Turn off interrupts completely, we're at max prio - let r = critical_section::with(|_| f(&mut *ptr)); - r + critical_section::with(|_| f(&mut *ptr)) } else { let current = unsafe { (*PLIC_MX::ptr()) |
