summary refs log tree commit diff
diff options
context:
space:
mode:
authorAlyssa Ross <hi@alyssa.is>2020-02-03 22:55:56 +0000
committerAlyssa Ross <hi@alyssa.is>2020-02-11 16:40:32 +0000
commita365d1c3406b448c20dac93466d93d1df9755893 (patch)
treee986e555ca89985cb04a016f2da48354d7ced937
parent1567b172269b9abb68c16a585f9024475b2844e6 (diff)
downloadcrosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar.gz
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar.bz2
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar.lz
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar.xz
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.tar.zst
crosvm-a365d1c3406b448c20dac93466d93d1df9755893.zip
arch: unreachable! is more appropriate than panic!
-rw-r--r--arch/src/lib.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/src/lib.rs b/arch/src/lib.rs
index 16cd6fa..33259de 100644
--- a/arch/src/lib.rs
+++ b/arch/src/lib.rs
@@ -187,7 +187,7 @@ pub fn generate_pci_root(
             1 => PciInterruptPin::IntB,
             2 => PciInterruptPin::IntC,
             3 => PciInterruptPin::IntD,
-            _ => panic!(""), // Obviously not possible, but the compiler is not smart enough.
+            _ => unreachable!(), // Obviously not possible, but the compiler is not smart enough.
         };
         vm.register_irqfd_resample(&irqfd, &irq_resample_fd, irq_num)
             .map_err(DeviceRegistrationError::RegisterIrqfd)?;