From 3a3d1683552c4ac260db839b74d7fba614ee1801 Mon Sep 17 00:00:00 2001 From: chrysn Date: Wed, 11 Dec 2024 12:44:32 +0100 Subject: [PATCH] chore: explain clippy false-positive --- src/ariel-os-embassy-common/src/identity.rs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ariel-os-embassy-common/src/identity.rs b/src/ariel-os-embassy-common/src/identity.rs index 8c34b93b2..535f1ea47 100644 --- a/src/ariel-os-embassy-common/src/identity.rs +++ b/src/ariel-os-embassy-common/src/identity.rs @@ -125,6 +125,10 @@ pub trait DeviceId: Sized { } } +#[expect( + clippy::missing_panics_doc, + reason = "False positive. Clippy does not see that `u32::from_le_bytes(eui48[1..5].try_into().unwrap())` can not panic, even though the compiler produces panic free code." +)] fn generate_aai_mac_address( truncated_board_hash: [u8; 6], device_id_bytes: impl AsRef<[u8]>,