[Gmp-commit] /var/hg/gmp-proj/mini-gmp: Corrected previous change; mixed up m...

mercurial at gmplib.org mercurial at gmplib.org
Thu Jan 12 22:19:14 CET 2012


details:   /var/hg/gmp-proj/mini-gmp/rev/c2ee9441c83c
changeset: 74:c2ee9441c83c
user:      Niels M?ller <nisse at lysator.liu.se>
date:      Thu Jan 12 22:19:09 2012 +0100
description:
Corrected previous change; mixed up mp_ptr and mpz_ptr.

diffstat:

 mini-gmp.c |  4 ++--
 mini-gmp.h |  3 +++
 2 files changed, 5 insertions(+), 2 deletions(-)

diffs (32 lines):

diff -r 47b17318a7e1 -r c2ee9441c83c mini-gmp.c
--- a/mini-gmp.c	Thu Jan 12 20:49:35 2012 +0100
+++ b/mini-gmp.c	Thu Jan 12 22:19:09 2012 +0100
@@ -225,13 +225,13 @@
 
 #define MPZ_PTR_SWAP(x, y)						\
   do {									\
-    mp_ptr __mpz_ptr_swap__tmp = (x);					\
+    mpz_ptr __mpz_ptr_swap__tmp = (x);					\
     (x) = (y);								\
     (y) = __mpz_ptr_swap__tmp;						\
   } while (0)
 #define MPZ_SRCPTR_SWAP(x, y)						\
   do {									\
-    mp_srcptr __mpz_srcptr_swap__tmp = (x);			\
+    mpz_srcptr __mpz_srcptr_swap__tmp = (x);			\
     (x) = (y);								\
     (y) = __mpz_srcptr_swap__tmp;					\
   } while (0)
diff -r 47b17318a7e1 -r c2ee9441c83c mini-gmp.h
--- a/mini-gmp.h	Thu Jan 12 20:49:35 2012 +0100
+++ b/mini-gmp.h	Thu Jan 12 22:19:09 2012 +0100
@@ -53,6 +53,9 @@
 
 typedef __mpz_struct mpz_t[1];
 
+typedef __mpz_struct *mpz_ptr;
+typedef const __mpz_struct *mpz_srcptr;
+
 void mpn_copyi (mp_ptr, mp_srcptr, mp_size_t);
 void mpn_copyd (mp_ptr, mp_srcptr, mp_size_t);
 


More information about the gmp-commit mailing list