> > It is said that the object has a NULL-Pointer when I try to debug it?
> what object?
   the python one  'myNewPyType'



Sorry, I forgot to change:
   PySDLXMLNodeType = PyMyType
..above the corrections

// == PyMyExtention.c =================================================
.
:
typedef struct {
    PyObject_HEAD
    long lAttribute;
} PyMyObject;

static PyObject* PyMyObject_NewC (long lAttribute)
{
    PyMyObject *self;
    PyMyObject *type;

    self = new PyMyObject
    self->lAttribute = lAttribute;

    return (PyObject*)self;
}

static PyMethodDef PyMyObject_methods[] = {
    {"PyMyObject_NewC", (PyCFunction)PyMyObject_NewC, METH_NOARGS,
    "Create PyMyObject_NewC from C-Code"},
    {NULL}  /* Sentinel */
};

:

static PyTypeObject PyMyType = {
    PyObject_HEAD_INIT(NULL)
    :
};
//===================================================================/

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to