[Pyrex] ANN: Pyrex 0.9.4 - LValue Casts are Dead!
Lenard Lindstrom
len-l at telus.net
Thu Apr 20 18:11:30 CEST 2006
On 20 Apr 2006 at 21:50, Greg Ewing wrote:
> Lenard Lindstrom wrote:
>
> > When will an external C++ declaration ever be needed? Writing an
> > include file when one is missing for a C++ library will likely be
> > necessary anyways since class declarations are not possible with
> > Pyrex.
>
> To give you a sneak preview of what I have in mind:
>
> cdef char *silly() # This function uses "extern C" linkage
>
> cdef+ char *walk() # This function uses C++ linkage
>
> cdef+ struct Foo: # This is a C++ struct/class
> int spam
> virtual void grail(char *nun) # ...and consequently can have methods
>
> Generally, anything C++ will be declared with cdef+,
> and anything C will be declared with cdef. In the
> interests of simplicity and consistency, I would like
> to retain this rule even inside cdef extern from
> (or cdef+ extern from, for C++ header files).
>
> While you might get away with using cdef instead of
> cdef+ for some things in an external header, this will
> not be supported and will officially be regarded as
> illegal.
>
This is intriguing. Will this be just for handing external
declarations, or will new class declaration/definition be possible?
Lenard Lindstrom
<len-l at telus.net>
More information about the Pyrex
mailing list