summaryrefslogtreecommitdiff
path: root/mpz/tstbit.c
diff options
context:
space:
mode:
authorTorbjorn Granlund <tege@gmplib.org>2009-12-20 23:54:57 +0100
committerTorbjorn Granlund <tege@gmplib.org>2009-12-20 23:54:57 +0100
commit3ba1597c34eeddef0c820863d98ed9506c8d3e9c (patch)
tree967966420d447f3e630ca1cc85709b7f9c1e03af /mpz/tstbit.c
parenta6426a5313cac3c0fb05358e7d254653222f745f (diff)
downloadgmp-3ba1597c34eeddef0c820863d98ed9506c8d3e9c.tar.gz
Change all bit counts for bignums to use mp_bitcnt_t. Update documentation.
Diffstat (limited to 'mpz/tstbit.c')
-rw-r--r--mpz/tstbit.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/mpz/tstbit.c b/mpz/tstbit.c
index 37f1454a6..02133cc00 100644
--- a/mpz/tstbit.c
+++ b/mpz/tstbit.c
@@ -38,12 +38,12 @@ along with the GNU MP Library. If not, see http://www.gnu.org/licenses/. */
the limb_index >= abs_size test covers u=0 too. */
int
-mpz_tstbit (mpz_srcptr u, unsigned long bit_index)
+mpz_tstbit (mpz_srcptr u, mp_bitcnt_t bit_index)
{
mp_srcptr u_ptr = PTR(u);
mp_size_t size = SIZ(u);
unsigned abs_size = ABS(size);
- unsigned long limb_index = bit_index / GMP_NUMB_BITS;
+ mp_size_t limb_index = bit_index / GMP_NUMB_BITS;
mp_srcptr p = u_ptr + limb_index;
mp_limb_t limb;