[Pyrex] declear opaque type

King C. Shu kingshu at myrealbox.com
Thu May 1 18:44:09 CEST 2003


Many libraries use opaque data type which are hidden from
the user. The attributes of the type might change between
versions. Can pyrex let peopel work on an opaque type? 
At lease allow such type to be private to a .pyx file.

I just need to operate on the structs inside the extension module. 
There are no need to expose the structs to python.

Like:
Display *XOpenDisplay(char* display_name)
XCloseDisplay(Display *display)

I don't need to expose Display to python and I don't want to know
what is Display. But I cannot just open a display and then
close it without describe the Display struct in pyrex. There is no
such restriction if code an extension by hand. :(

Or did I miss something?




More information about the Pyrex mailing list