isnt_even_nor_odd/lib.rs
1use is_even_or_odd::IsEvenOrOdd;
2
3pub trait IsntEvenNorOdd {
4 fn isnt_even_nor_odd(&self) -> bool;
5}
6
7macro_rules! prim_impl {
8 ($($t:tt)*) => {
9 $(
10 impl IsntEvenNorOdd for $t {
11 fn isnt_even_nor_odd(&self) -> bool {
12 !self.is_even_or_odd()
13 }
14 }
15 )*
16 };
17}
18
19prim_impl!(i8 u8 i16 u16 i32 u32 i64 u64);