Skip to content

Commit 62d0729

Browse files
committed
clippy: apply latest fix
1 parent 3cbf209 commit 62d0729

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

uefi/src/proto/loaded_image.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,7 @@ impl LoadedImage {
9595
///
9696
/// [`load_options_as_cstr16`]: `Self::load_options_as_cstr16`
9797
#[must_use]
98-
pub fn load_options_as_bytes(&self) -> Option<&[u8]> {
98+
pub const fn load_options_as_bytes(&self) -> Option<&[u8]> {
9999
if self.0.load_options.is_null() {
100100
None
101101
} else {

uefi/src/proto/security/memory_protection.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ impl MemoryProtection {
9292
}
9393

9494
/// Convert a byte `Range` to `(base_address, length)`.
95-
fn range_to_base_and_len(r: Range<PhysicalAddress>) -> (PhysicalAddress, PhysicalAddress) {
95+
const fn range_to_base_and_len(r: Range<PhysicalAddress>) -> (PhysicalAddress, PhysicalAddress) {
9696
(r.start, r.end.checked_sub(r.start).unwrap())
9797
}
9898

0 commit comments

Comments
 (0)