Instantiating Python class from C

Arno Puder arno at research.att.com
Mon Dec 10 17:40:24 EST 2001


Hi,

assume I have a Python class, defined through the interpreter. How do I 
instantiate a new object of this class in C within an extension of the 
Python interpreter. E.g.,

# Python
class A:
   #...

// C
PyObject* new_A_object = ???

Thanks,
Arno




More information about the Python-list mailing list