On Tue, 10 May 2022 at 18:06, anthony.flury via Python-ideas <python-ideas@python.org> wrote: > > A proposal for a new tool to be implemented - > > It is often the case that developer write Code in Python and then convert to > a C extension module for performance regions. > > A C extension module has a lot of boiler plate code - for instance the > Structures required for each class, the functions for Module initialization > etc. > > My Idea is a simple tool that uses introspection tools to take a Python > module and to generate the relevant boiler plate for the module - including > blank functions for the module classes and for methods. This tool would use > type annotations (if given) to make sensible choices for parameter and > attribute types, including using int and float directly rather than Internal > objects (depending on tool options). >
Yep, that's an awesome idea! Are you aware of Cython? You might be able to make use of that. ChrisA _______________________________________________ Python-ideas mailing list -- python-ideas@python.org To unsubscribe send an email to python-ideas-le...@python.org https://mail.python.org/mailman3/lists/python-ideas.python.org/ Message archived at https://mail.python.org/archives/list/python-ideas@python.org/message/UPX5FD2S2GAEDMZWUCSTHHQQSOFOQ6CX/ Code of Conduct: http://python.org/psf/codeofconduct/