creating factory methods in C extension modules.

  • Thread starter Patrick Stinson
  • Start date
P

Patrick Stinson

Cheerseating an C extension module that returns one of my C-defined python
classes from a factory function. is it correct to simple have the factory
function allocate and init the object by calling the functions I defined and
set as tp_new and tp_init in the PyTypeObject? If not am I supposed to use
PyObject_New and PyObject_Init or something?

Cherrs,
-P
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,764
Messages
2,569,567
Members
45,041
Latest member
RomeoFarnh

Latest Threads

Top