[Pyrex] Pyrex hard case
Greg Ewing
greg at cosc.canterbury.ac.nz
Tue Apr 29 08:05:31 CEST 2003
rdrb at 123.cl writesL:
> Basically there is a Macro function that I can't map to Pyrex, so I
> create an equivalent dummy function and hand edit the .c file erasing
> the definition.
What exactly does this macro look like? It's hard to give
any advice without knowing just how difficult a case we're
talking about.
> There should be way to define some "macro functions" or something that
> like, that allow you to define a prototype without including it into
> the definitions of the C code
You can already do that if you can get away with pretending
that the macro is really a function, e.g.
cdef extern from "somefile.h":
foo *blarg_macro(int, spam *)
Because it's inside a "cdef extern from", Pyrex doesn't
generate any declaration for blarg_macro, and the C
compiler picks up the real definition from the .h file.
Greg Ewing, Computer Science Dept, +--------------------------------------+
University of Canterbury, | A citizen of NewZealandCorp, a |
Christchurch, New Zealand | wholly-owned subsidiary of USA Inc. |
greg at cosc.canterbury.ac.nz +--------------------------------------+
More information about the Pyrex
mailing list