[Patches] [ python-Patches-1619846 ] Bug fixes for int unification branch

SourceForge.net noreply at sourceforge.net
Thu Dec 21 22:22:50 CET 2006


Patches item #1619846, was opened at 2006-12-21 03:36
Message generated for change (Comment added) made by loewis
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1619846&group_id=5470

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Adam Olsen (rhamphoryncus)
Assigned to: Martin v. Löwis (loewis)
Summary: Bug fixes for int unification branch

Initial Comment:
This patch should fix all the real bugs in the int unification branch.  All the remaining bugs are either external to the branch or due to tests that need updating (mostly due to the names of int vs long).

External bugs:
    test_socket: http://sourceforge.net/tracker/index.php?func=detail&aid=1619659&group_id=5470&atid=105470
    test_class: seems to be caused by using new-style classes by default.  Unrelated to int-unification.
    test_set: inheritance of __hash__.  I believe this was fixed in p3yk already.
Test failures due to naming differences:
    test_ctypes test_doctest test_generators test_genexps test_optparse test_pyexpat 
Tests needing updating, not just due to name differences:
    test_descr test_pickletools 


The following aspects need specific review:

PyLong_FromVoidPtr was doing the cast wrong.  GCC was compiling the (unsigned Py_LONG_LONG)p cast in such a way as to produce a value larger than 2**32, obviously wrong on this 32bit box, and it warned about the cast too.  Making it cast to Py_uintptr_t first seems to have corrected both the behaviour and the warning, but may be wrong on other architectures.

Many of my changes to use PyInt_CheckExact may be better served by creating a PyInt_CheckSmall macro that retains the range check but allows subclasses.  Alternatively, the index interface could be used, but would require more rewriting perhaps best left until later.

There are some areas that handled signed vs unsigned and int vs long a bit differently, and they may still need work.  Hard to tell what behaviour is correct in such cases.


Skipped files:
Doc/ext/run-func.c
Mac/Modules/ctl/_Ctlmodule.c
Mac/Modules/dlg/_Dlgmodule.c
Mac/Modules/win/_Winmodule.c
Mac/Modules/pycfbridge.c
Modules/carbonevt/_CarbonEvtmodule.c
Modules/_sqlite/connection.c
Modules/almodule.c
Modules/cgensupport.c
Modules/clmodule.c
Modules/flmodule.c
Modules/grpmodule.c
Modules/posicmodule.c:conv_confname
Modules/pyexpat.c
Modules/svmodule.c
Modules/termios.c
Modules/_bsddb.c
Modules/_sqlite/statement.c
PC/_winreg.c
Python/dynload_beos.c
Python/mactoolboxglue.c
Python/marshal.c
Python/pythonrun.c:handle_system_exit
RISCOS/Modules/drawfmodule.c
RISCOS/Modules/swimodule.c

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

>Comment By: Martin v. Löwis (loewis)
Date: 2006-12-21 22:22

Message:
Logged In: YES 
user_id=21627
Originator: NO

Not this year anymore. I'll try to early next year (hopefully first week
of January).

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

Comment By: Guido van Rossum (gvanrossum)
Date: 2006-12-21 22:12

Message:
Logged In: YES 
user_id=6380
Originator: NO

Martin, do you have time to look at this?  I'll play with it too but I'd
like to have your opinion.

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

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


More information about the Patches mailing list