annotate tests/test-exp2l-ieee.c @ 17921:58c1b50299a6

getopt: give accurate ambiguity diagnostic on mem exhaustion * lib/getopt.c (_getopt_internal_r): The previous commit broke out the loop too early, which could give a false indication of ambiguous options under memory exhaustion.
author Pádraig Brady <P@draigBrady.com>
date Wed, 18 Feb 2015 22:37:31 +0000
parents ab58d4870664
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
16627
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
1 /* Test of exp2l() function.
17848
ab58d4870664 version-etc: new year
Paul Eggert <eggert@cs.ucla.edu>
parents: 17587
diff changeset
2 Copyright (C) 2012-2015 Free Software Foundation, Inc.
16627
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
3
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
4 This program is free software: you can redistribute it and/or modify
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
5 it under the terms of the GNU General Public License as published by
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
6 the Free Software Foundation; either version 3 of the License, or
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
7 (at your option) any later version.
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
8
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
9 This program is distributed in the hope that it will be useful,
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
10 but WITHOUT ANY WARRANTY; without even the implied warranty of
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
11 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
12 GNU General Public License for more details.
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
13
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
14 You should have received a copy of the GNU General Public License
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
15 along with this program. If not, see <http://www.gnu.org/licenses/>. */
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
16
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
17 #include <config.h>
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
18
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
19 #include <math.h>
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
20
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
21 #include "isnanl-nolibm.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
22 #include "minus-zero.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
23 #include "infinity.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
24 #include "nan.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
25 #include "macros.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
26
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
27 #undef INFINITY
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
28 #undef NAN
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
29
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
30 #define DOUBLE long double
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
31 #define ISNAN isnanl
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
32 #define INFINITY Infinityl ()
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
33 #define NAN NaNl ()
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
34 #define L_(literal) literal##L
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
35 #define MINUS_ZERO minus_zerol
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
36 #define EXP2 exp2l
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
37 #include "test-exp2-ieee.h"
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
38
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
39 int
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
40 main ()
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
41 {
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
42 test_function ();
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
43
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
44 return 0;
e67eb36407a3 Tests for module 'exp2l-ieee'.
Bruno Haible <bruno@clisp.org>
parents:
diff changeset
45 }