From 335f6fa2ec578986b840fa668a9daad7878455a3 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Thu, 26 Sep 2024 20:22:06 -0700 Subject: [PATCH] factor: simplify table count * src/factor.c (PRIMES_PTAB_ENTRIES): Simplify. --- src/factor.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/factor.c b/src/factor.c index 9b90dbab0d..4bb4d4a53a 100644 --- a/src/factor.c +++ b/src/factor.c @@ -637,8 +637,7 @@ static const unsigned char primes_diff[] = { }; #undef P -#define PRIMES_PTAB_ENTRIES \ - (sizeof (primes_diff) / sizeof (primes_diff[0]) - 8 + 1) +#define PRIMES_PTAB_ENTRIES (ARRAY_CARDINALITY (primes_diff) - 8 + 1) #define P(a,b,c,d) b, static const unsigned char primes_diff8[] = { -- 2.47.2