[Python-bugs-list] [ python-Bugs-629989 ] int("123123123123123123") doesn't work

noreply@sourceforge.net noreply@sourceforge.net
Wed, 06 Nov 2002 08:00:50 -0800


Bugs item #629989, was opened at 2002-10-28 12:33
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=629989&group_id=5470

Category: Type/class unification
Group: Python 2.3
Status: Open
>Resolution: Accepted
Priority: 5
Submitted By: Guido van Rossum (gvanrossum)
>Assigned to: Walter Dörwald (doerwalter)
>Summary: int("123123123123123123") doesn't work

Initial Comment:
Now that we're trying to remove the difference between
int and long, it seems fair that int() of a very long
decimal string should return a long rather than raising
ValueError.

----------------------------------------------------------------------

>Comment By: Guido van Rossum (gvanrossum)
Date: 2002-11-06 11:00

Message:
Logged In: YES 
user_id=6380

If it works, check it in.

----------------------------------------------------------------------

Comment By: Walter Dörwald (doerwalter)
Date: 2002-11-06 09:27

Message:
Logged In: YES 
user_id=89016

How about the following patch (diff.txt): In addition to
creating longs when necessary, it fixes the problem of the
fixed 512 char unicode conversion buffer.

What should we do about int(1e200)?


----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=629989&group_id=5470