aboutsummaryrefslogtreecommitdiffstats
path: root/src/factor.c
diff options
context:
space:
mode:
authorPádraig Brady <P@draigBrady.com>2021-04-11 18:23:21 +0100
committerPádraig Brady <P@draigBrady.com>2021-04-11 18:33:45 +0100
commitef772bf97f7ec577754cbb5b278504d83cf41a43 (patch)
treeb6553bdc35b4d08368d427dbb3bb790acf43129c /src/factor.c
parentls: cache name width determination (diff)
downloadcoreutils-ef772bf97f7ec577754cbb5b278504d83cf41a43.tar.gz
coreutils-ef772bf97f7ec577754cbb5b278504d83cf41a43.zip
maint: use "char const *" rather than "const char *"
* cfg.mk (sc_prohibit-const-char): Add a new syntax-check to enforce this style. * *.[ch]: sed -i 's/const char \*/char const */g'
Diffstat (limited to 'src/factor.c')
-rw-r--r--src/factor.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/factor.c b/src/factor.c
index f77d6d057..d1a6bb8e7 100644
--- a/src/factor.c
+++ b/src/factor.c
@@ -2256,7 +2256,7 @@ mp_factor (mpz_t t, struct mp_factors *factors)
}
static strtol_error
-strto2uintmax (uintmax_t *hip, uintmax_t *lop, const char *s)
+strto2uintmax (uintmax_t *hip, uintmax_t *lop, char const *s)
{
unsigned int lo_carry;
uintmax_t hi = 0, lo = 0;
@@ -2264,7 +2264,7 @@ strto2uintmax (uintmax_t *hip, uintmax_t *lop, const char *s)
strtol_error err = LONGINT_INVALID;
/* Initial scan for invalid digits. */
- const char *p = s;
+ char const *p = s;
for (;;)
{
unsigned int c = *p++;
@@ -2461,7 +2461,7 @@ print_factors_single (uintmax_t t1, uintmax_t t0)
has enough digits, because the algorithm is better. The turnover point
depends on the value. */
static bool
-print_factors (const char *input)
+print_factors (char const *input)
{
/* Skip initial spaces and '+'. */
char const *str = input;