Merge pull request #6241 from cakebaker/factor_allow_dead_code

factor: suppress some "never used" warnings
This commit is contained in:
Sylvestre Ledru 2024-04-15 20:09:37 +02:00 committed by GitHub
commit 40600f2419
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -13,6 +13,7 @@ use num_traits::{
};
use std::fmt::{Debug, Display};
#[allow(dead_code)] // Rust doesn't recognize the use in the macro
pub(crate) trait Int:
Display + Debug + PrimInt + OverflowingAdd + WrappingNeg + WrappingSub + WrappingMul
{
@ -23,6 +24,7 @@ pub(crate) trait Int:
fn as_u128(&self) -> u128;
}
#[allow(dead_code)] // Rust doesn't recognize the use in the macro
pub(crate) trait DoubleInt: Int {
/// An integer type with twice the width of `Self`.
/// In particular, multiplications (of `Int` values) can be performed in