version 1.1, 2002/12/19 20:14:58
|
version 1.2, 2003/01/02 16:48:12
|
Line 27
|
Line 27
|
#include <unistd.h> |
#include <unistd.h> |
#include <pwd.h> |
#include <pwd.h> |
#include <dirent.h> |
#include <dirent.h> |
|
#include <math.h> |
|
|
#ifdef HAS_FILE |
#ifdef HAS_FILE |
char *cstr(Char *from, UCell size, int clear) |
char *cstr(Char *from, UCell size, int clear) |
Line 129 Xt *primtable(Label symbols[], Cell size
|
Line 130 Xt *primtable(Label symbols[], Cell size
|
xts[i] = &symbols[i]; |
xts[i] = &symbols[i]; |
return xts; |
return xts; |
} |
} |
|
|
|
DCell double2ll(Float r) |
|
{ |
|
#ifndef BUGGY_LONG_LONG |
|
return (DCell)(r); |
|
#else |
|
double ldexp(double x, int exp); |
|
DCell d; |
|
if (r<0) { |
|
d.hi = ldexp(-r,-(int)(CELL_BITS)); |
|
d.lo = (-r)-ldexp((Float)d.hi,CELL_BITS); |
|
return dnegate(d); |
|
} |
|
d.hi = ldexp(r,-(int)(CELL_BITS)); |
|
d.lo = r-ldexp((Float)d.hi,CELL_BITS); |
|
return d; |
|
#endif |
|
} |