Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJeff Johnston <jjohnstn@redhat.com>2005-10-15 01:11:39 +0400
committerJeff Johnston <jjohnstn@redhat.com>2005-10-15 01:11:39 +0400
commitd2c2c1328b5fa59452a0d7e945abeed2fa72fb58 (patch)
tree4defeefaba2172387d8e965537214f43d1be1bb8 /newlib/libc
parent4d57c1edc7e1f4ac2c6656a014c90454225df138 (diff)
2005-10-14 Jeff Johnston <jjohnstn@redhat.com>
* libc/include/math.h (HUGE_VALF, HUGE_VALL): New. * libm/common/Makefile.am: Add s_infconst.c support. * libm/common/Makefile.in: Regenerated. * libm/common/s_infconst.c: New file with float and long double infinity support added. * libm/math/Makefile.am: Remove s_infconst.c support. * libm/math/Makefile.in: Regenerated. * libm/math/s_infconst.c: Moved to common directory. * libm/mathfp/Makefile.am: Remove s_infconst.c support. * libm/mathfp/Makefile.in: Regenerated. * libm/mathfp/s_infconst.c: Moved to common directory.
Diffstat (limited to 'newlib/libc')
-rw-r--r--newlib/libc/include/math.h16
1 files changed, 16 insertions, 0 deletions
diff --git a/newlib/libc/include/math.h b/newlib/libc/include/math.h
index 36766809e..3eec0e48f 100644
--- a/newlib/libc/include/math.h
+++ b/newlib/libc/include/math.h
@@ -14,18 +14,34 @@ _BEGIN_STD_C
/* Define HUGE_VAL as infinity, unless HUGE_VAL is already defined
(which might have been done by something like math-68881.h). */
+union __fmath
+{
+ __ULong i[1];
+ float f;
+};
+
union __dmath
{
__ULong i[2];
double d;
};
+union __ldmath
+{
+ __ULong i[4];
+ _LONG_DOUBLE ld;
+};
+
/* Declare this as an array without bounds so that no matter what small data
support a port and/or library has, this reference will be via the general
method for accessing globals. */
extern __IMPORT const union __dmath __infinity[];
+extern __IMPORT const union __fmath __infinityf[];
+extern __IMPORT const union __ldmath __infinityld[];
#define HUGE_VAL (__infinity[0].d)
+#define HUGE_VALF (__infinityf[0].f)
+#define HUGE_VALL (__infinityld[0].ld)
#endif /* ! defined (HUGE_VAL) */