source: trunk/third/libxml2/trionan.h @ 18210

Revision 18210, 2.0 KB checked in by ghudson, 21 years ago (diff)
This commit was generated by cvs2svn to compensate for changes in r18209, which included commits to RCS files with non-trunk default branches.
Line 
1/*************************************************************************
2 *
3 * $Id: trionan.h,v 1.1.1.2 2002-12-26 06:43:06 ghudson Exp $
4 *
5 * Copyright (C) 2001 Bjorn Reese <breese@users.sourceforge.net>
6 *
7 * Permission to use, copy, modify, and distribute this software for any
8 * purpose with or without fee is hereby granted, provided that the above
9 * copyright notice and this permission notice appear in all copies.
10 *
11 * THIS SOFTWARE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR IMPLIED
12 * WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED WARRANTIES OF
13 * MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE AUTHORS AND
14 * CONTRIBUTORS ACCEPT NO RESPONSIBILITY IN ANY CONCEIVABLE MANNER.
15 *
16 ************************************************************************/
17
18#ifndef TRIO_NAN_H
19#define TRIO_NAN_H
20
21#include "triodef.h"
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
27enum {
28  TRIO_FP_INFINITE,
29  TRIO_FP_NAN,
30  TRIO_FP_NORMAL,
31  TRIO_FP_SUBNORMAL,
32  TRIO_FP_ZERO
33};
34
35/*
36 * Return NaN (Not-a-Number).
37 */
38TRIO_PUBLIC double trio_nan TRIO_PROTO((void));
39
40/*
41 * Return positive infinity.
42 */
43TRIO_PUBLIC double trio_pinf TRIO_PROTO((void));
44
45/*
46 * Return negative infinity.
47 */
48TRIO_PUBLIC double trio_ninf TRIO_PROTO((void));
49 
50/*
51 * Return negative zero.
52 */
53TRIO_PUBLIC double trio_nzero TRIO_PROTO((TRIO_NOARGS));
54
55/*
56 * If number is a NaN return non-zero, otherwise return zero.
57 */
58TRIO_PUBLIC int trio_isnan TRIO_PROTO((double number));
59
60/*
61 * If number is positive infinity return 1, if number is negative
62 * infinity return -1, otherwise return 0.
63 */
64TRIO_PUBLIC int trio_isinf TRIO_PROTO((double number));
65
66/*
67 * If number is finite return non-zero, otherwise return zero.
68 */
69TRIO_PUBLIC int trio_isfinite TRIO_PROTO((double number));
70
71TRIO_PUBLIC int trio_signbit TRIO_PROTO((double number));
72
73TRIO_PUBLIC int trio_fpclassify TRIO_PROTO((double number));
74
75TRIO_PUBLIC int trio_fpclassify_and_signbit TRIO_PROTO((double number, int *is_negative));
76
77#ifdef __cplusplus
78}
79#endif
80
81#endif /* TRIO_NAN_H */
Note: See TracBrowser for help on using the repository browser.