[Pyrex] Interpreting error messages

Edward C. Jones edcjones at erols.com
Sun Apr 27 16:17:51 CEST 2003


The program is:

#include <stdio.h>

cdef tostring(void* p):
     cdef char* s
     s = <char*> malloc(50*sizeof(char))
     sprintf(s, c"%p", p)
     return s

The error messages are:

/.../silly.pyx:5:8: Casting temporary Python object to non-Python type
/.../silly.pyx:6:22: Cannot convert 'void (*)' to Python object

What are my errors?






More information about the Pyrex mailing list