[Pyrex] Same type does not resolve to itself when coming in through different .pxd files

Dan Gindikin dg at pnylab.com
Mon Nov 19 16:42:35 CET 2007


Here is my setup, I tried it with 0.9.5.1a and 0.9.6.3, both give 
"main.pyx:4:31: Expected ')'".

mymodule.pxd
	ctypedef struct F:
		int i
		
	cdef class base:
		cdef void func(self, F x)
		
mymodule.pyx
	cdef class base:
		cdef void func(self, F x):
			pass
			
main.pyx
	cimport mymodule

	cdef class derived(mymodule.base):
		cdef void func(self, F x):
			pass
			
run.sh
	#!/bin/sh

	#cmd="python Pyrex-0.9.5.1a/pyrexc.py"
	cmd="python Pyrex-0.9.6.3/pyrexc.py"

	$cmd mymodule.pyx	# runs fine
	$cmd main.pyx		# generates error "main.pyx:4:31: Expected ')'"


Greg Ewing wrote:
> You should certainly be able to do that. Tell me more
> about the syntax errors and I'll see if I can help.
> 
> -- 
> Greg


-- 
Dan



More information about the Pyrex mailing list