mirror of
https://github.com/cloud-hypervisor/cloud-hypervisor.git
synced 2026-08-05 02:19:16 +00:00
misc: Fix beta clippy issues
Fixed with 'cargo clippy --fix' mostly. Signed-off-by: Bo Chen <bchen@crusoe.ai>
This commit is contained in:
@@ -50,8 +50,9 @@ use crate::MigratableError;
|
||||
// The source can at any time send an "abandon request" to cancel
|
||||
|
||||
#[repr(u16)]
|
||||
#[derive(Copy, Clone)]
|
||||
#[derive(Copy, Clone, Default)]
|
||||
pub enum Command {
|
||||
#[default]
|
||||
Invalid,
|
||||
Start,
|
||||
Config,
|
||||
@@ -62,12 +63,6 @@ pub enum Command {
|
||||
MemoryFd,
|
||||
}
|
||||
|
||||
impl Default for Command {
|
||||
fn default() -> Self {
|
||||
Self::Invalid
|
||||
}
|
||||
}
|
||||
|
||||
#[repr(C)]
|
||||
#[derive(Default, Copy, Clone)]
|
||||
pub struct Request {
|
||||
@@ -139,19 +134,14 @@ impl Request {
|
||||
}
|
||||
|
||||
#[repr(u16)]
|
||||
#[derive(Copy, Clone, PartialEq, Eq)]
|
||||
#[derive(Copy, Clone, PartialEq, Eq, Default)]
|
||||
pub enum Status {
|
||||
#[default]
|
||||
Invalid,
|
||||
Ok,
|
||||
Error,
|
||||
}
|
||||
|
||||
impl Default for Status {
|
||||
fn default() -> Self {
|
||||
Self::Invalid
|
||||
}
|
||||
}
|
||||
|
||||
#[repr(C)]
|
||||
#[derive(Default, Copy, Clone)]
|
||||
pub struct Response {
|
||||
|
||||
Reference in New Issue
Block a user