From aa9d0fff74ac854a3491ab95718a0dc577b648f3 Mon Sep 17 00:00:00 2001 From: Philipp Oppermann Date: Wed, 15 Jan 2025 19:58:23 +0100 Subject: [PATCH] Code: Use new `&raw const` operator instead of `unsafe {& _}` --- src/gdt.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gdt.rs b/src/gdt.rs index e7ffdc989..05b074d11 100644 --- a/src/gdt.rs +++ b/src/gdt.rs @@ -12,7 +12,7 @@ lazy_static! { const STACK_SIZE: usize = 4096 * 5; static mut STACK: [u8; STACK_SIZE] = [0; STACK_SIZE]; - let stack_start = VirtAddr::from_ptr(unsafe { &STACK }); + let stack_start = VirtAddr::from_ptr(&raw const STACK); let stack_end = stack_start + STACK_SIZE; stack_end };