[Patches] [ python-Patches-1498441 ] Change *args from a tuple to list
SourceForge.net
noreply at sourceforge.net
Thu Jun 1 21:32:55 CEST 2006
Patches item #1498441, was opened at 2006-05-31 15:30
Message generated for change (Comment added) made by collinwinter
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1498441&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: Core (C code)
Group: Python 3000
Status: Open
Resolution: None
Priority: 5
Submitted By: Collin Winter (collinwinter)
Assigned to: Guido van Rossum (gvanrossum)
Summary: Change *args from a tuple to list
Initial Comment:
As discussed on python-3000, this patch changes *args
from a tuple to a list. It also includes doc and test
changes.
The patch is against r46582.
----------------------------------------------------------------------
>Comment By: Collin Winter (collinwinter)
Date: 2006-06-01 15:32
Message:
Logged In: YES
user_id=1344176
As requested by Neal Norwitz, some benchmarking (all times
in usecs per loop):
./python -mtimeit 'def foo(*args): pass' 'foo()'
As tuple: 1.56
As list: 1.7
./python -mtimeit 'def foo(*args): pass' 'foo(1)'
As tuple: 1.75
As list: 2.04
./python -mtimeit 'def foo(*args): pass' 'foo(1, 2)'
As tuple: 1.87
As list: 2.15
./python -mtimeit 'def foo(*args): pass' 'foo(1, 2, 3)'
As tuple: 1.95
As list: 2.3
./python -mtimeit 'def foo(*args): pass' 'foo(1, 2, 3, 4, 5,
6, 7, 8, 9, 10)'
As tuple: 2.67
As list: 2.97
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=305470&aid=1498441&group_id=5470
More information about the Patches
mailing list