Thank you very much. Of course I know how to do it in python. The problem is that I want to reimplement these classes as a python extension in C. The question is: how can I add class members (like e.g. inner classes) to a PyTypeObject defined in a C extension?
- harold - > You can define a class variable Pos with the class Pos as its value > > class PeriodicGrid : > class Pos: > pass > Pos = Pos > > >>> grid = PeriodicGrid() > >>> grid.Pos() > <__main__.Pos instance at 0x00EEFAD0> > > Ciao > Kay -- http://mail.python.org/mailman/listinfo/python-list