summaryrefslogtreecommitdiff
path: root/tests/tinits.c
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2003-09-11 16:49:11 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2003-09-11 16:49:11 +0000
commit1c24e6a15a2eddc5145422d5b6321ee14eac288e (patch)
tree4191f7113b3bd472100f16dc847ae51e3cd5c790 /tests/tinits.c
parent101429a324956af3411efa6209af9597a3d7f4f1 (diff)
downloadmpfr-1c24e6a15a2eddc5145422d5b6321ee14eac288e.tar.gz
New functions mpfr_inits, mpfr_inits2 and mpfr_clears to initialize or
free several floating-point numbers (written by Patrick PĂ©lissier). git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@2409 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tests/tinits.c')
-rw-r--r--tests/tinits.c38
1 files changed, 38 insertions, 0 deletions
diff --git a/tests/tinits.c b/tests/tinits.c
new file mode 100644
index 000000000..6f5db3c69
--- /dev/null
+++ b/tests/tinits.c
@@ -0,0 +1,38 @@
+/* Test file for mpfr_inits, mpfr_inits2 and mpfr_clears.
+
+Copyright 2003 Free Software Foundation.
+
+This file is part of the MPFR Library.
+
+The MPFR Library is free software; you can redistribute it and/or modify
+it under the terms of the GNU Lesser General Public License as published by
+the Free Software Foundation; either version 2.1 of the License, or (at your
+option) any later version.
+
+The MPFR Library is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
+or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
+License for more details.
+
+You should have received a copy of the GNU Lesser General Public License
+along with the MPFR Library; see the file COPYING.LIB. If not, write to
+the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
+MA 02111-1307, USA. */
+
+#include "gmp.h"
+#include "mpfr.h"
+#include "mpfr-test.h"
+
+int
+main (void)
+{
+ mpfr_t a, b, c;
+
+ tests_start_mpfr ();
+ mpfr_inits (a, b, c, (mpfr_ptr) 0);
+ mpfr_clears (a, b, c, (mpfr_ptr) 0);
+ mpfr_inits2 (200, a, b, c, (mpfr_ptr) 0);
+ mpfr_clears (a, b, c, (mpfr_ptr) 0);
+ tests_end_mpfr ();
+ return 0;
+}