diff options
author | enge <enge@211d60ee-9f03-0410-a15a-8952a2c7a4e4> | 2011-11-04 20:30:22 +0000 |
---|---|---|
committer | enge <enge@211d60ee-9f03-0410-a15a-8952a2c7a4e4> | 2011-11-04 20:30:22 +0000 |
commit | dad757aa5dede68e460c626aa372d1a79f252dc5 (patch) | |
tree | 333dd2fd36c1f9d25cfc57ff3d458292ac1a994a | |
parent | b8faa5864516b203ebd28963f61e0ee14effc131 (diff) | |
download | mpc-dad757aa5dede68e460c626aa372d1a79f252dc5.tar.gz |
mpc-tests.h: reorganisation of comment
test files: remove inclusion of stdio.h, done via mpc-tests.h
git-svn-id: svn://scm.gforge.inria.fr/svn/mpc/trunk@1116 211d60ee-9f03-0410-a15a-8952a2c7a4e4
-rw-r--r-- | tests/mpc-tests.h | 30 | ||||
-rw-r--r-- | tests/tcosh.c | 1 | ||||
-rw-r--r-- | tests/tget_version.c | 1 | ||||
-rw-r--r-- | tests/tio_str.c | 2 | ||||
-rw-r--r-- | tests/tsqr.c | 1 |
5 files changed, 14 insertions, 21 deletions
diff --git a/tests/mpc-tests.h b/tests/mpc-tests.h index 664aa1b..5416108 100644 --- a/tests/mpc-tests.h +++ b/tests/mpc-tests.h @@ -33,21 +33,6 @@ along with this program. If not, see http://www.gnu.org/licenses/ . #define MPC_MAX_PREC(x) MPC_MAX(MPC_PREC_RE(x), MPC_PREC_IM(x)) #define MPC_MAX(h,i) ((h) > (i) ? (h) : (i)) -#define MPC_OUT(x) \ -do { \ - printf (#x "[%lu,%lu]=", (unsigned long int) MPC_PREC_RE (x), \ - (unsigned long int) MPC_PREC_IM (x)); \ - mpc_out_str (stdout, 2, 0, x, MPC_RNDNN); \ - printf ("\n"); \ -} while (0) - -#define MPFR_OUT(x) \ -do { \ - printf (#x "[%lu]=", (unsigned long int) mpfr_get_prec (x)); \ - mpfr_out_str (stdout, 2, 0, x, GMP_RNDN); \ - printf ("\n"); \ -} while (0) - #define MPC_ASSERT(expr) \ do { \ if (!(expr)) \ @@ -60,9 +45,22 @@ do { \ __MPC_DECLSPEC int mpc_mul_naive __MPC_PROTO ((mpc_ptr, mpc_srcptr, mpc_srcptr, mpc_rnd_t)); __MPC_DECLSPEC int mpc_mul_karatsuba __MPC_PROTO ((mpc_ptr, mpc_srcptr, mpc_srcptr, mpc_rnd_t)); +/* end pieces copied from mpc-impl.h */ +#define MPC_OUT(x) \ +do { \ + printf (#x "[%lu,%lu]=", (unsigned long int) MPC_PREC_RE (x), \ + (unsigned long int) MPC_PREC_IM (x)); \ + mpc_out_str (stdout, 2, 0, x, MPC_RNDNN); \ + printf ("\n"); \ +} while (0) -/* end pieces copied from mpc-impl.h */ +#define MPFR_OUT(x) \ +do { \ + printf (#x "[%lu]=", (unsigned long int) mpfr_get_prec (x)); \ + mpfr_out_str (stdout, 2, 0, x, GMP_RNDN); \ + printf ("\n"); \ +} while (0) #define MPC_INEX_STR(inex) \ diff --git a/tests/tcosh.c b/tests/tcosh.c index 8a4a88d..57b5601 100644 --- a/tests/tcosh.c +++ b/tests/tcosh.c @@ -18,7 +18,6 @@ You should have received a copy of the GNU Lesser General Public License along with this program. If not, see http://www.gnu.org/licenses/ . */ -#include <stdio.h> #include <stdlib.h> #include "mpc-tests.h" diff --git a/tests/tget_version.c b/tests/tget_version.c index 445c2ed..2d42f3f 100644 --- a/tests/tget_version.c +++ b/tests/tget_version.c @@ -18,7 +18,6 @@ You should have received a copy of the GNU Lesser General Public License along with this program. If not, see http://www.gnu.org/licenses/ . */ -#include <stdio.h> #include <string.h> #include <stdlib.h> #include "mpc-tests.h" diff --git a/tests/tio_str.c b/tests/tio_str.c index a169f89..af5a669 100644 --- a/tests/tio_str.c +++ b/tests/tio_str.c @@ -18,8 +18,6 @@ You should have received a copy of the GNU Lesser General Public License along with this program. If not, see http://www.gnu.org/licenses/ . */ -#include <stdio.h> - #include "mpc-tests.h" #ifdef HAVE_UNISTD_H diff --git a/tests/tsqr.c b/tests/tsqr.c index db1fd72..02fea7e 100644 --- a/tests/tsqr.c +++ b/tests/tsqr.c @@ -18,7 +18,6 @@ You should have received a copy of the GNU Lesser General Public License along with this program. If not, see http://www.gnu.org/licenses/ . */ -#include <stdio.h> #include <stdlib.h> #include "mpc-tests.h" |