Skip to content

Commit b8aff21

Browse files
committed
Minor deduplication for tests macro
1 parent 05941db commit b8aff21

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

library/core/tests/num/int_sqrt.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
macro_rules! tests {
2-
($($T:ident $isqrt_consistency_check_fn_macro:ident),+) => {
2+
($isqrt_consistency_check_fn_macro:ident : $($T:ident)+) => {
33
$(
44
mod $T {
55
$isqrt_consistency_check_fn_macro!($T);
@@ -230,5 +230,5 @@ macro_rules! unsigned_check {
230230
};
231231
}
232232

233-
tests!(i8 signed_check, i16 signed_check, i32 signed_check, i64 signed_check, i128 signed_check);
234-
tests!(u8 unsigned_check, u16 unsigned_check, u32 unsigned_check, u64 unsigned_check, u128 unsigned_check);
233+
tests!(signed_check: i8 i16 i32 i64 i128);
234+
tests!(unsigned_check: u8 u16 u32 u64 u128);

0 commit comments

Comments
 (0)