[Python-3000] Two proposals for a new list-like type: one modest, one radical (original) (raw)
Neal Norwitz nnorwitz at gmail.com
Tue Apr 24 06:25:09 CEST 2007
- Previous message: [Python-3000] Two proposals for a new list-like type: one modest, one radical
- Next message: [Python-3000] Two proposals for a new list-like type: one modest, one radical
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On 4/23/07, Daniel Stutzbach <daniel at stutzbachenterprises.com> wrote:
The Radical Proposal ------------------------------- Replace list() with the BList.
I looked over this patch and have various questions/comments. In rough priority order:
I'm concerned about the moderately heavy use of macros wrt to debugging.
I noticed the use of alloca(). This isn't used in the core anywhere (except a few uses on Windows). That might be an issue. I didn't check how it was used.
I noticed that calculating the height was recursive. Not sure where this function was called from, but does it handle blists which contain themselves?
Have you tried running this code under regrtest.py with the -R flag to check for memory leaks?
There were C++ (//) style comments and C99 declarations of variables. These would have to be changed if included in the core. Also, size_t and Py_ssize_t should be used throughout. (ssize_t should be Py_ssize_t). I noticed a bunch of ints and unsigneds. Although I also noticed you used PyIndex_Check().
In general I thought the code was pretty good. Had a decent amount of error checking/handling. There were some cases I wasn't sure, but in the paths that I traced, I didn't find any obvious problems.
n
- Previous message: [Python-3000] Two proposals for a new list-like type: one modest, one radical
- Next message: [Python-3000] Two proposals for a new list-like type: one modest, one radical
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]