add match_same_arms clippy lint (#8549)

This commit is contained in:
Thomas Coratger
2024-06-03 19:42:25 +02:00
committed by GitHub
parent 0f1bad98f2
commit e02b935e94
34 changed files with 259 additions and 310 deletions

View File

@ -191,10 +191,10 @@ impl Error {
Self::WannaRecovery => ffi::MDBX_WANNA_RECOVERY,
Self::KeyMismatch => ffi::MDBX_EKEYMISMATCH,
Self::DecodeErrorLenDiff | Self::DecodeError => ffi::MDBX_EINVAL,
Self::Access => ffi::MDBX_EACCESS,
Self::TooLarge => ffi::MDBX_TOO_LARGE,
Self::BadSignature => ffi::MDBX_EBADSIGN,
Self::WriteTransactionUnsupportedInReadOnlyMode => ffi::MDBX_EACCESS,
Self::Access |
Self::WriteTransactionUnsupportedInReadOnlyMode |
Self::NestedTransactionsUnsupportedWithWriteMap => ffi::MDBX_EACCESS,
Self::ReadTransactionTimeout => -96000, // Custom non-MDBX error code
Self::Other(err_code) => *err_code,