diff options
-rw-r--r-- | big.c | 51 |
1 files changed, 0 insertions, 51 deletions
@@ -991,55 +991,4 @@ word bigtostr8(word x) return r; } -#ifdef DEBUG -/* check for well-formation of integer */ -wff(word x) -{ - word y = x; - if (tag[x] != INT) { - printf("BAD TAG %d\n", tag[x]); - } - - if (big_is_negative(x) && !digit0(x) && !rest(x)) { - printf("NEGATIVE ZERO!\n"); - } - - if (digit0(x) & (~MAXDIGIT)) { - printf("OVERSIZED DIGIT!\n"); - } - - while (x = rest(x)) { - if (tag[x] != INT) { - printf("BAD INTERNAL TAG %d\n", tag[x]); - } else if (digit(x) & (~MAXDIGIT)) { - printf("OVERSIZED DIGIT!\n"); - } else if (!digit(x) && !rest(x)) { - printf("TRAILING ZERO!\n"); - } - } - - return (y); -} - -/* remove trailing zeros */ -normalise(word x) -{ - if (rest(x)) { - rest(x) = norm1(rest(x)); - } - - return wff(x); -} - -norm1(word x) -{ - if (rest(x)) { - rest(x) = norm1(rest(x)); - } - - return (!digit(x) && !rest(x) ? 0 : x); -} - -#endif - /* END OF MIRANDA INTEGER PACKAGE */ |