[Python-3000] Two proposals for a new list-like type: one modest, one radical
Guido van Rossum
guido at python.org
Mon Apr 23 20:38:07 CEST 2007
On 4/23/07, Daniel Stutzbach <daniel at stutzbachenterprises.com> wrote:
> I have two proposals for Python 3000 that I'll write PEP(s) for if
> there's interest. The first proposal is, I think, a modest one. The
> second proposal is related, but more radical. I fully expect the
> second proposal to be rejected for that alone, especially since I am a
> relatively an outsider to the Python developer community (though it
> was great to meet some of you at PyCon this year). I bring up the
> more radical proposal primarily for completeness.
> The Modest Proposal
> As a pet project, I've written a container type that looks, acts, and
> quacks like a Python list(), but has better asymptotic performance.
> Specifically, O(log n) time for inserts and deletes in the middle of
> the list. I'd like to offer it for inclusion in the collections
> The Radical Proposal
> Replace list() with the BList.
(1) You really need Raymond Hettinger's review. Nothing else matters much.
(2) I'm against proliferation of data types, because it makes the
choices for developers harder. For that reason, I'd be against the
modest proposal without the radical proposal. But I'd be in favor of
the radical proposal if the pragmatics (mostly of existing core code
and 3rd party extensions using the PyList_* APIs) can be solved, and
if the performance is uniformly better.
--Guido van Rossum (home page: http://www.python.org/~guido/)
More information about the Python-3000