Index: ChangeLog =================================================================== RCS file: /cvsroot/guile/guile/guile-core/libguile/ChangeLog,v retrieving revision 1.1465.2.18 diff -u -u -p -r1.1465.2.18 ChangeLog --- ChangeLog 2001/08/26 21:49:49 1.1465.2.18 +++ ChangeLog 2001/09/01 12:51:33 @@ -1,3 +1,8 @@ +2001-09-01 Martin Baulig + + * num2integral.i.c (NUM2INTEGRAL): Ensure that unsigned bigs are + always positive. + 2001-08-26 Marius Vollmer * ports.c, ports.h, fprots.c, gc.c, ioext.c: Replaced Index: num2integral.i.c =================================================================== RCS file: /cvsroot/guile/guile/guile-core/libguile/num2integral.i.c,v retrieving revision 1.4 diff -u -u -p -r1.4 num2integral.i.c --- num2integral.i.c 2001/06/27 13:15:20 1.4 +++ num2integral.i.c 2001/09/01 12:51:34 @@ -47,14 +47,17 @@ NUM2INTEGRAL (SCM num, unsigned long int res = new; } -#ifndef UNSIGNED if (SCM_BIGSIGN (num)) { +#ifdef UNSIGNED + scm_out_of_range (s_caller, num); +#else res = -res; if (res <= 0) return res; else scm_out_of_range (s_caller, num); +#endif } else { @@ -63,7 +66,6 @@ NUM2INTEGRAL (SCM num, unsigned long int else scm_out_of_range (s_caller, num); } -#endif return res; }