[Python-Dev] Access to generator type
James William Pye
flaw at rhid.com
Thu May 20 12:42:46 EDT 2004
On 05/10/04:19/1, Tim Peters wrote:
> Possibly, if someone wants it enough to make a patch (including doc
> changes). There are many types that aren't exposed at the C level, BTW.
> Advertising their internals has an inhibiting effect on evolution. The
> generator type has been around long enough w/o change that the value in
> keeping it private has diminished.
Okay, here's a preliminary patch with genobject.[ch]:
http://sourceforge.net/tracker/index.php?func=detail&aid=957398&group_id=5470&atid=305470
I assumed(yay) that py-dev would want it inline with how other core objects
are managed(*object.[ch]), so I spun it out into its own files in
/Object/genobject.c and /Include/genobject.h..
Of course, genobject.c references eval_frame(in ceval.c), which raises a
problem; currently it is resolved in my tree by making a wrapper in
ceval.c(PyEval_EvaluateFrame(){eval_frame()}). This is unlikely to be an
acceptable solution, and I'm not sure how py-dev wants this to be handled.
Keep it in its own genobject.[ch] and get eval_frame how?
Or keep it in ceval.[ch]?
The latter seems to be the right choice to me, but less pertty.
Regards,
James William Pye
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 479 bytes
Desc: not available
Url : http://mail.python.org/pipermail/python-dev/attachments/20040520/0898db7c/attachment.bin
More information about the Python-Dev
mailing list