Re: PEP 489: Redesigning extension module loading; version 4

Nick Coghlan <[email protected]> Thu, 14 May 2015 02:04:24 +1000
Newsgroups gmane.comp.python.import
Message-ID <CADiSq7friGngVNL-SqaWHE8imCHQROy6jBuTe4xAdSqf7e0wrg@mail.gmail.com>
On 14 May 2015 at 00:31, Petr Viktorin <[email protected]> wrote:
> Or, I could keep the "PyInit_*" hook name, and allow it to return
> PyModuleDef instead of a module. This is obviously a hack, and would
> force me to get back down to the drawing board, but considering the
> options it seems best to explore this option.
> (PyInit_* and PyModuleExport_* signatures are technically compatible,
> since a PyModuleDef is a PyObject)
>
> I'd welcome your thoughts.

Would it be feasible to go with a model where _PyImport_inittab
continues to be based on the legacy extension module initialisation
system for the time being? That would mean implementing PyInit_* would
remain required rather than optional for 3.5, but lots of folks are
going to want to provide it anyway for compatibility with 3.4 and
earlier.

Cheers,
Nick.

-- 
Nick Coghlan   |   [email protected]   |   Brisbane, Australia