Reid Kleckner <r...@mit.edu> added the comment:

This patch looks good to me, after digging through the relevant module code.

I was confused though for a bit as to why PyModuleDef is a PyObject with a NULL 
type.  It turns out that import.c wants to keep them in a dictionary, so it 
needs to be able to cast to PyObject* and to access the refcount.  It never 
needs the type, though, so it's safe to leave it NULL.  I think it might be 
worth adding comments explaining that in this patch or another.

----------
nosy: +rnk

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue7576>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to