You don't need to test whether you have the bug -- I'm sure you have
it, but in case you're interested, it turns out that -2L compares
greater than -1L ... Apply this patch to longobject and it's fixed...
(Not that you care -- or else why did nobody complain before?)
===================================================================
RCS file: /ufs/guido/CVSROOT/python/src/longobject.c,v
retrieving revision 1.17
diff -c -1 -r1.17 longobject.c
*** 1.17 1992/09/17 17:54:47
--- longobject.c 1993/01/18 09:16:05
***************
*** 608,611 ****
sign = 0;
! else
sign = (int)a->ob_digit[i] - (int)b->ob_digit[i];
}
--- 608,614 ----
sign = 0;
! else {
sign = (int)a->ob_digit[i] - (int)b->ob_digit[i];
+ if (a->ob_size < 0)
+ sign = -sign;
+ }
}
===================================================================
Note that this doesn't mean I'll soon bring out a new release -- 0.9.8
appears quite stable, there have been a number of problem reports but
these all pertain to minor things that can be fixed by massaging the
Makefile a little bit, or they are very platform-specific (hallo Jaap!).
Cheers,
--Guido van Rossum, CWI, Amsterdam <Guido.van.Rossum@cwi.nl>