Skip to content

Commit

Permalink
fix: clippy
Browse files Browse the repository at this point in the history
Signed-off-by: Woshiluo Luo <[email protected]>
  • Loading branch information
woshiluo committed Oct 29, 2024
1 parent 2865dd1 commit a76362d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/de.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ where

let total_size = u32::from_be(header.total_size);
let raw_data_len = (total_size - HEADER_LEN) as usize;
let ans_ptr = core::ptr::from_raw_parts(ptr as *const u8, raw_data_len);
let ans_ptr = core::ptr::from_raw_parts(ptr, raw_data_len);
let device_tree: &DeviceTree = &*ans_ptr;
let tags = device_tree.tags();
let mut d = Deserializer {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ pub trait DeviceTreeTraversal {
}
}

impl<'de> DeviceTreeTraversal for Node<'de> {
impl DeviceTreeTraversal for Node<'_> {
/// Try to get a node by path
fn find(&self, path: &str) -> Option<Node> {
// Direct return root node
Expand Down

0 comments on commit a76362d

Please sign in to comment.