History

20120103-2107

forsyth committed 14 years ago

Commit 0de61ca1 parent a098dea14 files · +76 −10Browse files

Unified · Split

14 files
  1. CHANGES +2 −0
  2. DragonFly/386/include/lib9.h +9 −1
  3. FreeBSD/386/include/lib9.h +9 −1
  4. MacOSX/386/include/lib9.h +9 −1
  5. MacOSX/power/include/lib9.h +9 −1
  6. NetBSD/386/include/lib9.h +9 −1
  7. OpenBSD/386/include/lib9.h +9 −1
  8. include/version.h +1 −1
  9. lib9/isnan-posix.c +15 −0
  10. lib9/mkfile-Nt +1 −0
  11. lib9/mkfile-Posix +1 −0
  12. libinterp/math.c +1 −1
  13. libmath/mkfile +0 −1
  14. limbo/nodes.c +1 −1
CHANGES+2−0
@@ -1,3 +1,5 @@
1+20120103
2+ avoid re-defining isnan; use isNaN instead
13 20111231
24 Linux/*/include/emu.h adjustments for USE_PTHREADS for non-x86 processors
35 20111221
DragonFly/386/include/lib9.h+9−1
@@ -20,7 +20,6 @@ · 19 unmodified lines
2020
2121 #define getwd infgetwd
2222
23−#undef isnan
2423 #define round infround
2524 #define fmax inffmax
2625 #define log2 inflog2
@@ -49,6 +48,15 @@ typedef unsigned short u16int; · 22 unmodified lines
4948 typedef unsigned char u8int;
5049 typedef unsigned long uintptr;
5150
51+typedef signed char int8;
52+typedef unsigned char uint8;
53+typedef short int16;
54+typedef unsigned short uint16;
55+typedef int int32;
56+typedef unsigned int uint32;
57+typedef long long int64;
58+typedef unsigned long long uint64;
59+
5260 #define USED(x) if(x){}else{}
5361 #define SET(x)
5462
FreeBSD/386/include/lib9.h+9−1
@@ -20,7 +20,6 @@ · 19 unmodified lines
2020
2121 #define getwd infgetwd
2222
23−#undef isnan
2423 #define round infround
2524 #define fmax inffmax
2625 #define log2 inflog2
@@ -50,6 +49,15 @@ typedef unsigned short u16int; · 23 unmodified lines
5049 typedef unsigned char u8int;
5150 typedef unsigned long uintptr;
5251
52+typedef signed char int8;
53+typedef unsigned char uint8;
54+typedef short int16;
55+typedef unsigned short uint16;
56+typedef int int32;
57+typedef unsigned int uint32;
58+typedef long long int64;
59+typedef unsigned long long uint64;
60+
5361 #define USED(x) if(x){}else{}
5462 #define SET(x)
5563
MacOSX/386/include/lib9.h+9−1
@@ -43,6 +43,15 @@ typedef unsigned short u16int; · 42 unmodified lines
4343 typedef unsigned char u8int;
4444 typedef unsigned long uintptr;
4545
46+typedef signed char int8;
47+typedef unsigned char uint8;
48+typedef short int16;
49+typedef unsigned short uint16;
50+typedef int int32;
51+typedef unsigned int uint32;
52+typedef long long int64;
53+typedef unsigned long long uint64;
54+
4655 /* handle conflicts with host os libs */
4756 #define getwd infgetwd
4857 #define scalb infscalb
@@ -50,7 +59,6 @@ typedef unsigned long uintptr; · 1 unmodified line
5059 #define panic infpanic
5160 #define rint infrint
5261 #define rcmd infrcmd
53−#undef isnan
5462 #define pow10 infpow10
5563
5664 #ifndef EMU
MacOSX/power/include/lib9.h+9−1
@@ -43,6 +43,15 @@ typedef unsigned short u16int; · 42 unmodified lines
4343 typedef unsigned char u8int;
4444 typedef unsigned long uintptr;
4545
46+typedef signed char int8;
47+typedef unsigned char uint8;
48+typedef short int16;
49+typedef unsigned short uint16;
50+typedef int int32;
51+typedef unsigned int uint32;
52+typedef long long int64;
53+typedef unsigned long long uint64;
54+
4655 /* handle conflicts with host os libs */
4756 #define getwd infgetwd
4857 #define scalb infscalb
@@ -50,7 +59,6 @@ typedef unsigned long uintptr; · 1 unmodified line
5059 #define panic infpanic
5160 #define rint infrint
5261 #define rcmd infrcmd
53−#undef isnan
5462 #define pow10 infpow10
5563
5664 #ifndef EMU
NetBSD/386/include/lib9.h+9−1
@@ -15,7 +15,6 @@ · 14 unmodified lines
1515
1616 #define getwd infgetwd
1717
18−#undef isnan
1918 #define round infround
2019 #define fmax inffmax
2120 #define log2 inflog2
@@ -49,6 +48,15 @@ typedef uvlong u64int; · 27 unmodified lines
4948
5049 typedef uintptr_t uintptr;
5150
51+typedef signed char int8;
52+typedef unsigned char uint8;
53+typedef short int16;
54+typedef unsigned short uint16;
55+typedef int int32;
56+typedef unsigned int uint32;
57+typedef long long int64;
58+typedef unsigned long long uint64;
59+
5260 typedef unsigned short Rune;
5361 typedef unsigned int mpdigit; /* for /sys/include/mp.h */
5462
OpenBSD/386/include/lib9.h+9−1
@@ -20,7 +20,6 @@ · 19 unmodified lines
2020
2121 #define getwd infgetwd
2222
23−#undef isnan
2423 #define round infround
2524 #define fmax inffmax
2625 #define log2 inflog2
@@ -50,6 +49,15 @@ typedef unsigned short u16int; · 23 unmodified lines
5049 typedef unsigned char u8int;
5150 typedef unsigned long uintptr;
5251
52+typedef signed char int8;
53+typedef unsigned char uint8;
54+typedef short int16;
55+typedef unsigned short uint16;
56+typedef int int32;
57+typedef unsigned int uint32;
58+typedef long long int64;
59+typedef unsigned long long uint64;
60+
5361 #define USED(x) if(x){}else{}
5462 #define SET(x)
5563
include/version.h+1−1
@@ -1 +1 @@
1−#define VERSION "Fourth Edition (20111231)"
1+#define VERSION "Fourth Edition (20120103)"
lib9/isnan-posix.c+15−0
@@ -0,0 +1,15 @@
1+#include <lib9.h>
2+
3+int
4+isNaN(double d)
5+{
6+ return isnan(d);
7+}
8+
9+int
10+isInf(double d, int sign)
11+{
12+ if(sign < 0)
13+ return isinf(d) < 0;
14+ return isinf(d);
15+}
lib9/mkfile-Nt+1−0
@@ -7,3 +7,4 @@ TARGFILES=\ · 6 unmodified lines
77 setbinmode-Nt.$O\
88 lock-Nt-386.$O\
99 pread-Nt.$O\
10+ isnan-posix.$O\
lib9/mkfile-Posix+1−0
@@ -6,3 +6,4 @@ TARGFILES=\ · 5 unmodified lines
66 getcallerpc-$SYSTARG-$OBJTYPE.$O\
77 getwd-posix.$O\
88 sbrk-posix.$O\
9+ isnan-posix.$O\
libinterp/math.c+1−1
@@ -274,7 +274,7 @@ Math_isnan(void *fp) · 273 unmodified lines
274274
275275 f = fp;
276276
277− *f->ret = isnan(f->x);
277+ *f->ret = isNaN(f->x);
278278 }
279279
280280 void
libmath/mkfile+0−1
@@ -48,7 +48,6 @@ OFILES=\ · 47 unmodified lines
4848 s_finite.$O\
4949 s_floor.$O\
5050 s_ilogb.$O\
51− s_isnan.$O\
5251 s_log1p.$O\
5352 s_nextafter.$O\
5453 s_rint.$O\
limbo/nodes.c+1−1
@@ -1045,7 +1045,7 @@ foldr(Node *n) · 1044 unmodified lines
10451045 n->left = nil;
10461046 n->right = nil;
10471047
1048− if(isnan(rv))
1048+ if(isNaN(rv))
10491049 rv = canonnan;
10501050
10511051 n->rval = rv;