Apply x clippy --fix and x fmt
This commit is contained in:
parent
f2e1a3a80a
commit
dabd05bbab
14 changed files with 28 additions and 30 deletions
|
@ -69,7 +69,7 @@ impl Hasher for FxHasher {
|
|||
hash.add_to_hash(u16::from_ne_bytes(bytes[..2].try_into().unwrap()) as usize);
|
||||
bytes = &bytes[2..];
|
||||
}
|
||||
if (size_of::<usize>() > 1) && bytes.len() >= 1 {
|
||||
if (size_of::<usize>() > 1) && !bytes.is_empty() {
|
||||
hash.add_to_hash(bytes[0] as usize);
|
||||
}
|
||||
self.hash = hash.hash;
|
||||
|
|
|
@ -264,9 +264,9 @@ impl From<Box<dyn Any + Send>> for PanicMessage {
|
|||
}
|
||||
}
|
||||
|
||||
impl Into<Box<dyn Any + Send>> for PanicMessage {
|
||||
fn into(self) -> Box<dyn Any + Send> {
|
||||
match self {
|
||||
impl From<PanicMessage> for Box<dyn Any + Send> {
|
||||
fn from(val: PanicMessage) -> Self {
|
||||
match val {
|
||||
PanicMessage::StaticStr(s) => Box::new(s),
|
||||
PanicMessage::String(s) => Box::new(s),
|
||||
PanicMessage::Unknown => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue