[Python-checkins] r46225 - sandbox/trunk/newstruct/Modules/_newstruct.c

Thomas Wouters thomas at python.org
Thu May 25 19:33:28 CEST 2006


On 5/25/06, bob.ippolito <python-checkins at python.org> wrote:

> +       if (x <= INT_MAX)
> +               return PyInt_FromLong((long)x);


This ought to be LONG_MAX instead of INT_MAX; PyInts hold C longs, not C
ints. There's only a difference on LP64 architectures (all 64-bit
architectures except Win64, basically) but testing for INT_MAX would be
pessimistic there.

-- 
Thomas Wouters <thomas at python.org>

Hi! I'm a .signature virus! copy me into your .signature file to help me
spread!
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/python-checkins/attachments/20060525/38f7bca0/attachment.html 


More information about the Python-checkins mailing list