From 7aef56ca320bad9d72fbddd6e334381773e23d37 Mon Sep 17 00:00:00 2001 From: iximeow Date: Sat, 30 May 2026 19:13:14 +0000 Subject: useless use of unsafe --- test/protected_mode/behavior.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'test/protected_mode/behavior.rs') diff --git a/test/protected_mode/behavior.rs b/test/protected_mode/behavior.rs index 0fa8637..13c4c51 100644 --- a/test/protected_mode/behavior.rs +++ b/test/protected_mode/behavior.rs @@ -15,9 +15,7 @@ mod kvm { fn host_decoder() -> protected_mode::InstDecoder { // Safety: it's cpuid, everything supports leaf eax=1. - let leaf1 = unsafe { - core::arch::x86_64::__cpuid(1) - }; + let leaf1 = core::arch::x86_64::__cpuid(1); match leaf1.eax { 0x00b40f40 => { // zen 5 (my 9950x) -- cgit v1.1