[Cython] Syntax to declare a c++ class?
Robert Bradshaw
robertwb at math.washington.edu
Thu May 7 04:37:12 CEST 2009
On May 6, 2009, at 7:26 PM, Danilo Freitas wrote:
> 2009/5/6 Greg Ewing <greg.ewing at canterbury.ac.nz>:
>> Robert Bradshaw wrote:
>>> On May 6, 2009, at 1:33 PM, Dag Sverre Seljebotn wrote:
>>>> cdef extern "C++" from "myheader.h":
>>>> cdef class A: ...
>>
>> For Pyrex I'm thinking about using "cdef+" as a
>> general prefix for C++-related declarations, e.g.
>>
>> cdef+ extern from "myheader.hpp":
>> ...
>>
>> cdef+ struct Foo:
>> ...
> I think this is weird. But it's a solution. I don't see many problems
> with cppdef.
It's too close to cpdef I think. I asked about this during our sage
dev meeting today and people seemed to like
cdef cppclass Foo:
....
- Robert
More information about the Cython-dev
mailing list