Defining inheritance in C extensions
Alexander Gavrilov
agavrilov at home.com
Fri Nov 9 20:07:08 EST 2001
Probably it's not what you're looking for, but you can take a look on ASPN
recipe called "Defining Python class methods in C". Here is the link:
http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/54352
--
Alexander Gavrilov
Brainbench MVP for C++
http://www.brainbench.com
"Timo Savola" <timo.savola at iki.fi> wrote in message
news:mailman.1005261310.27106.python-list at python.org...
> Hello. I'm new to this list, and relatively new to Python (played around
> with it every now and then, and used it as a calculator :).
>
> Now I'm doing an extension module, or rather a system that I want to
> control via Python. I have a C++ class hierarchy that I want to be
> accessible from Python. I can't figure out how to make a type object a
> subclass of another type object, so that I can do type checking in the
> Python wrappers of my methods.
>
> I've been browsing the Extending and Embedding section of the Python
> documentation (version 2.2). Is it just me, or has the Defining New
> Types section fallen short? It doesn't say anything about /* Attribute
> descriptor and subclassing stuff */...
>
> Is there a more extensive reference to extending Python, or maybe some
> comprehensive example code on the subject?
>
> Thanks in advance. :)
>
> Timo
>
>
More information about the Python-list
mailing list