[Python-checkins] r51492 - in python/branches/int_unification: Include/boolobject.h Include/intobject.h Include/longobject.h Modules/_sre.c Objects/abstract.c Objects/boolobject.c Objects/exceptions.c Objects/intobject.c Objects/listobject.c Objects/longobject.c Python/bltinmodule.c Python/marshal.c Python/pythonrun.c

Nick Coghlan ncoghlan at gmail.com
Wed Aug 23 13:51:07 CEST 2006


M.-A. Lemburg wrote:
>> Log:
>> Drop the int type.
> 
> Wouldn't it be better to add the long implementation on top
> of the int implementation rather than replacing int with
> long ?

There's a reason MvL is doing this on a branch - the idea is to benchmark the 
status quo (which he's done), merge int & long into a single type (which is 
naturally the current PyLong, as it is a complete functional replacement for 
int, albeit slower), and then optimise the C level integers *inside the long 
type*.

If the merged type can provide comparable performance to the two separate 
types, then it can become the 'int' type in Py3k, with 'long' being a 
historical relic existing only in the 2.x series.

Cheers,
Nick.

-- 
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia
---------------------------------------------------------------
             http://www.boredomandlaziness.org


More information about the Python-checkins mailing list