diff options
| author | Mattias Andrée <maandree@kth.se> | 2016-04-27 00:39:31 +0200 |
|---|---|---|
| committer | Mattias Andrée <maandree@kth.se> | 2016-04-27 00:39:31 +0200 |
| commit | eb13267f82e848d9a9b38a2791e5c7008bf8d157 (patch) | |
| tree | 78291e85edd590b0d429a0dab611b85c621d97d7 /bench/libgmp.h | |
| parent | zstr_length.3: add missing blank space (diff) | |
| download | libzahl-eb13267f82e848d9a9b38a2791e5c7008bf8d157.tar.gz libzahl-eb13267f82e848d9a9b38a2791e5c7008bf8d157.tar.bz2 libzahl-eb13267f82e848d9a9b38a2791e5c7008bf8d157.tar.xz | |
zstr: add new parameter, n: the known limit out the length of the output
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to 'bench/libgmp.h')
| -rw-r--r-- | bench/libgmp.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bench/libgmp.h b/bench/libgmp.h index 95a518d..42b2d1e 100644 --- a/bench/libgmp.h +++ b/bench/libgmp.h @@ -91,7 +91,7 @@ zunsetup(void) #define zmodpowu mpz_powm_ui #define zsets(a, s) mpz_set_str(a, s, 10) #define zstr_length(a, b) (mpz_sizeinbase(a, 10) + (zsignum(a) < 0)) -#define zstr(a, s) mpz_get_str(s, 10, a) +#define zstr(a, s, n) ((void)n, mpz_get_str(s, 10, a)) #define zptest(w, a, t) mpz_probab_prime_p(a, t) /* Note, the witness is not returned. */ #define zdiv mpz_tdiv_q #define zmod mpz_tdiv_r |
