debian/external_deps/fetk/punc/src/vf2c/signbit.c
raw| 1 | #include "arith.h" |
| 2 | |
| 3 | #ifndef Long |
| 4 | #define Long long |
| 5 | #endif |
| 6 | |
| 7 | int |
| 8 | #ifdef KR_headers |
| 9 | signbit_f2c(x) double *x; |
| 10 | #else |
| 11 | signbit_f2c(double *x) |
| 12 | #endif |
| 13 | { |
| 14 | #ifdef IEEE_MC68k |
| 15 | if (*(Long*)x & 0x80000000) |
| 16 | return 1; |
| 17 | #else |
| 18 | #ifdef IEEE_8087 |
| 19 | if (((Long*)x)[1] & 0x80000000) |
| 20 | return 1; |
| 21 | #endif /*IEEE_8087*/ |
| 22 | #endif /*IEEE_MC68k*/ |
| 23 | return 0; |
| 24 | } |