(
expected: T::Bits,
value: T,
inherent: impl FnOnce(&T) -> T::Bits,
)
| 25 | |
| 26 | #[track_caller] |
| 27 | fn case<T: Flags + std::fmt::Debug>( |
| 28 | expected: T::Bits, |
| 29 | value: T, |
| 30 | inherent: impl FnOnce(&T) -> T::Bits, |
| 31 | ) where |
| 32 | T::Bits: std::fmt::Debug + PartialEq, |
| 33 | { |
| 34 | assert_eq!(expected, inherent(&value), "{:?}.bits()", value); |
| 35 | assert_eq!(expected, Flags::bits(&value), "Flags::bits({:?})", value); |
| 36 | } |